* [PATCH 1/2] irda: Use __packed annotation instead IRDA_PACKED macro
@ 2010-07-21 20:59 Gustavo F. Padovan
2010-07-21 20:59 ` [PATCH 2/2] net: remove last uses of __attribute__((packed)) Gustavo F. Padovan
2010-07-21 21:10 ` [PATCH 1/2] irda: Use __packed annotation instead IRDA_PACKED macro David Miller
0 siblings, 2 replies; 4+ messages in thread
From: Gustavo F. Padovan @ 2010-07-21 20:59 UTC (permalink / raw)
To: netdev; +Cc: davem, linux-kernel
Remove IRDA_PACKED macro, which maps to __attribute__((packed)). IRDA is
one of the last users of __attribute__((packet)). Networking code uses
__packed now.
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
---
include/net/irda/irda.h | 4 ----
include/net/irda/irlap_frame.h | 18 +++++++++---------
2 files changed, 9 insertions(+), 13 deletions(-)
diff --git a/include/net/irda/irda.h b/include/net/irda/irda.h
index 7e58206..3bed61d 100644
--- a/include/net/irda/irda.h
+++ b/include/net/irda/irda.h
@@ -53,10 +53,6 @@ typedef __u32 magic_t;
#ifndef IRDA_ALIGN
# define IRDA_ALIGN __attribute__((aligned))
#endif
-#ifndef IRDA_PACK
-# define IRDA_PACK __attribute__((packed))
-#endif
-
#ifdef CONFIG_IRDA_DEBUG
diff --git a/include/net/irda/irlap_frame.h b/include/net/irda/irlap_frame.h
index 641f88e..6b1dc4f 100644
--- a/include/net/irda/irlap_frame.h
+++ b/include/net/irda/irlap_frame.h
@@ -85,7 +85,7 @@ struct discovery_t;
struct disc_frame {
__u8 caddr; /* Connection address */
__u8 control;
-} IRDA_PACK;
+} __packed;
struct xid_frame {
__u8 caddr; /* Connection address */
@@ -96,41 +96,41 @@ struct xid_frame {
__u8 flags; /* Discovery flags */
__u8 slotnr;
__u8 version;
-} IRDA_PACK;
+} __packed;
struct test_frame {
__u8 caddr; /* Connection address */
__u8 control;
__le32 saddr; /* Source device address */
__le32 daddr; /* Destination device address */
-} IRDA_PACK;
+} __packed;
struct ua_frame {
__u8 caddr;
__u8 control;
__le32 saddr; /* Source device address */
__le32 daddr; /* Dest device address */
-} IRDA_PACK;
+} __packed;
struct dm_frame {
__u8 caddr; /* Connection address */
__u8 control;
-} IRDA_PACK;
+} __packed;
struct rd_frame {
__u8 caddr; /* Connection address */
__u8 control;
-} IRDA_PACK;
+} __packed;
struct rr_frame {
__u8 caddr; /* Connection address */
__u8 control;
-} IRDA_PACK;
+} __packed;
struct i_frame {
__u8 caddr;
__u8 control;
-} IRDA_PACK;
+} __packed;
struct snrm_frame {
__u8 caddr;
@@ -138,7 +138,7 @@ struct snrm_frame {
__le32 saddr;
__le32 daddr;
__u8 ncaddr;
-} IRDA_PACK;
+} __packed;
void irlap_queue_xmit(struct irlap_cb *self, struct sk_buff *skb);
void irlap_send_discovery_xid_frame(struct irlap_cb *, int S, __u8 s,
--
1.7.1.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH 2/2] net: remove last uses of __attribute__((packed))
2010-07-21 20:59 [PATCH 1/2] irda: Use __packed annotation instead IRDA_PACKED macro Gustavo F. Padovan
@ 2010-07-21 20:59 ` Gustavo F. Padovan
2010-07-21 21:10 ` David Miller
2010-07-21 21:10 ` [PATCH 1/2] irda: Use __packed annotation instead IRDA_PACKED macro David Miller
1 sibling, 1 reply; 4+ messages in thread
From: Gustavo F. Padovan @ 2010-07-21 20:59 UTC (permalink / raw)
To: netdev; +Cc: davem, linux-kernel
Network code uses the __packed macro instead of __attribute__((packed)).
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
---
include/net/mac80211.h | 2 +-
net/ipv4/netfilter/ipt_CLUSTERIP.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/net/mac80211.h b/include/net/mac80211.h
index 7f256e2..23e46ce 100644
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -412,7 +412,7 @@ struct ieee80211_tx_rate {
s8 idx;
u8 count;
u8 flags;
-} __attribute__((packed));
+} __packed;
/**
* struct ieee80211_tx_info - skb transmit information
diff --git a/net/ipv4/netfilter/ipt_CLUSTERIP.c b/net/ipv4/netfilter/ipt_CLUSTERIP.c
index 64d0875..3a43cf3 100644
--- a/net/ipv4/netfilter/ipt_CLUSTERIP.c
+++ b/net/ipv4/netfilter/ipt_CLUSTERIP.c
@@ -469,7 +469,7 @@ struct arp_payload {
__be32 src_ip;
u_int8_t dst_hw[ETH_ALEN];
__be32 dst_ip;
-} __attribute__ ((packed));
+} __packed;
#ifdef DEBUG
static void arp_print(struct arp_payload *payload)
--
1.7.1.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 1/2] irda: Use __packed annotation instead IRDA_PACKED macro
2010-07-21 20:59 [PATCH 1/2] irda: Use __packed annotation instead IRDA_PACKED macro Gustavo F. Padovan
2010-07-21 20:59 ` [PATCH 2/2] net: remove last uses of __attribute__((packed)) Gustavo F. Padovan
@ 2010-07-21 21:10 ` David Miller
1 sibling, 0 replies; 4+ messages in thread
From: David Miller @ 2010-07-21 21:10 UTC (permalink / raw)
To: padovan; +Cc: netdev, linux-kernel
From: "Gustavo F. Padovan" <padovan@profusion.mobi>
Date: Wed, 21 Jul 2010 17:59:57 -0300
> Remove IRDA_PACKED macro, which maps to __attribute__((packed)). IRDA is
> one of the last users of __attribute__((packet)). Networking code uses
> __packed now.
>
> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
Applied.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 2/2] net: remove last uses of __attribute__((packed))
2010-07-21 20:59 ` [PATCH 2/2] net: remove last uses of __attribute__((packed)) Gustavo F. Padovan
@ 2010-07-21 21:10 ` David Miller
0 siblings, 0 replies; 4+ messages in thread
From: David Miller @ 2010-07-21 21:10 UTC (permalink / raw)
To: padovan; +Cc: netdev, linux-kernel, linville
From: "Gustavo F. Padovan" <padovan@profusion.mobi>
Date: Wed, 21 Jul 2010 17:59:58 -0300
> Network code uses the __packed macro instead of __attribute__((packed)).
>
> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
Applied.
John, this might conflict with a wireless-next commit you made
recently, just FYI...
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2010-07-21 21:10 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-07-21 20:59 [PATCH 1/2] irda: Use __packed annotation instead IRDA_PACKED macro Gustavo F. Padovan
2010-07-21 20:59 ` [PATCH 2/2] net: remove last uses of __attribute__((packed)) Gustavo F. Padovan
2010-07-21 21:10 ` David Miller
2010-07-21 21:10 ` [PATCH 1/2] irda: Use __packed annotation instead IRDA_PACKED macro David Miller
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).