From: Andrew Cooper <andrew.cooper3@citrix.com>
To: Xen-devel <xen-devel@lists.xen.org>
Cc: Andrew Cooper <andrew.cooper3@citrix.com>,
Stefano Stabellini <stefano.stabellini@citrix.com>,
Ian Campbell <ian.campbell@citrix.com>, Tim Deegan <tim@xen.org>
Subject: [PATCH 4/5] xen/arm: Cleanup use of __attribute__((packed))
Date: Wed, 12 Mar 2014 19:08:38 +0000 [thread overview]
Message-ID: <1394651319-8893-5-git-send-email-andrew.cooper3@citrix.com> (raw)
In-Reply-To: <1394651319-8893-1-git-send-email-andrew.cooper3@citrix.com>
And standardise on having the statement at the head of the struct/union rather
than at the tail. This is all mechanical shuffling.
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
CC: Ian Campbell <ian.campbell@citrix.com>
CC: Stefano Stabellini <stefano.stabellini@citrix.com>
CC: Tim Deegan <tim@xen.org>
---
xen/include/asm-arm/page.h | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/xen/include/asm-arm/page.h b/xen/include/asm-arm/page.h
index e00be9e..6fe7fc5 100644
--- a/xen/include/asm-arm/page.h
+++ b/xen/include/asm-arm/page.h
@@ -94,7 +94,7 @@
* bits that's not in use in a given node type can be used as
* extra software-defined bits. */
-typedef struct {
+typedef struct __packed {
/* These are used in all kinds of entry. */
unsigned long valid:1; /* Valid mapping */
unsigned long table:1; /* == 1 in 4k map entries too */
@@ -126,11 +126,11 @@ typedef struct {
unsigned long xnt:1; /* eXecute-Never */
unsigned long apt:2; /* Access Permissions */
unsigned long nst:1; /* Not-Secure */
-} __attribute__((__packed__)) lpae_pt_t;
+} lpae_pt_t;
/* The p2m tables have almost the same layout, but some of the permission
* and cache-control bits are laid out differently (or missing) */
-typedef struct {
+typedef struct __packed {
/* These are used in all kinds of entry. */
unsigned long valid:1; /* Valid mapping */
unsigned long table:1; /* == 1 in 4k map entries too */
@@ -156,13 +156,13 @@ typedef struct {
unsigned long type:4; /* Ignore by hardware. Used to store p2m types */
unsigned long sbz1:5;
-} __attribute__((__packed__)) lpae_p2m_t;
+} lpae_p2m_t;
/*
* Walk is the common bits of p2m and pt entries which are needed to
* simply walk the table (e.g. for debug).
*/
-typedef struct {
+typedef struct __packed {
/* These are used in all kinds of entry. */
unsigned long valid:1; /* Valid mapping */
unsigned long table:1; /* == 1 in 4k map entries too */
@@ -173,7 +173,7 @@ typedef struct {
unsigned long base:28; /* Base address of block or next table */
unsigned long pad1:24;
-} __attribute__((__packed__)) lpae_walk_t;
+} lpae_walk_t;
typedef union {
uint64_t bits;
--
1.7.10.4
next prev parent reply other threads:[~2014-03-12 19:08 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-12 19:08 [PATCH 0/5] Improvements with __attribute__((packed)) Andrew Cooper
2014-03-12 19:08 ` [PATCH 1/5] xen: Remove redundant __attribute__((packed)) statements Andrew Cooper
2014-03-13 8:06 ` Jan Beulich
2014-03-13 10:38 ` Andrew Cooper
2014-03-13 10:49 ` George Dunlap
2014-03-12 19:08 ` [PATCH 2/5] xen/common: Cleanup use of __attribute__((packed)) Andrew Cooper
2014-03-13 8:15 ` Jan Beulich
2014-03-13 10:22 ` Andrew Cooper
2014-03-13 10:40 ` Jan Beulich
2014-03-13 10:42 ` Andrew Cooper
2014-03-12 19:08 ` [PATCH 3/5] xen/x86: " Andrew Cooper
2014-03-13 8:32 ` Jan Beulich
2014-03-13 11:00 ` Andrew Cooper
2014-03-13 11:13 ` Jan Beulich
2014-03-13 11:36 ` Keir Fraser
2014-03-12 19:08 ` Andrew Cooper [this message]
2014-03-13 8:34 ` [PATCH 4/5] xen/arm: " Jan Beulich
2014-03-13 9:55 ` Ian Campbell
2014-03-13 9:59 ` Tim Deegan
2014-03-13 10:01 ` Ian Campbell
2014-03-13 10:02 ` Jan Beulich
2014-03-12 19:08 ` [PATCH 5/5] DO NOT APPLY: for verification purposes only Andrew Cooper
2014-03-13 6:31 ` [PATCH 0/5] Improvements with __attribute__((packed)) Keir Fraser
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1394651319-8893-5-git-send-email-andrew.cooper3@citrix.com \
--to=andrew.cooper3@citrix.com \
--cc=ian.campbell@citrix.com \
--cc=stefano.stabellini@citrix.com \
--cc=tim@xen.org \
--cc=xen-devel@lists.xen.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).