From: Malcolm Priestley Date: Tue, 13 Aug 2013 18:47:08 +0000 (+0100) Subject: staging: vt6656: rxtx.h always pack BEACON_BUFFER/TX_BUFFER X-Git-Tag: MMI-PSA29.97-13-9~13778^2~264 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=629a9e65734e7a0d1b7528529ab99f5974f6069d;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git staging: vt6656: rxtx.h always pack BEACON_BUFFER/TX_BUFFER All structure members of BEACON_BUFFER/TX_BUFFER should be packed. Only the first 4 members of these structures are live. The forth member is referenced at run-time by packed structures. typedef struct tagSTxBufHead typedef struct tagSTxShortBufHead in desc.h If these structures are not packed the alignment of these members will be wrong. Signed-off-by: Malcolm Priestley Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/vt6656/rxtx.h b/drivers/staging/vt6656/rxtx.h index dd7e85dde1a2..d854b383d647 100644 --- a/drivers/staging/vt6656/rxtx.h +++ b/drivers/staging/vt6656/rxtx.h @@ -609,7 +609,7 @@ typedef struct tagSTX_BUFFER // Actual message TX_BUFFER_CONTAINER BufferHeader; -} TX_BUFFER, *PTX_BUFFER; +} __packed TX_BUFFER, *PTX_BUFFER; // // Remote NDIS message format @@ -626,7 +626,7 @@ typedef struct tagSBEACON_BUFFER // Actual message TX_BUFFER_CONTAINER BufferHeader; -} BEACON_BUFFER, *PBEACON_BUFFER; +} __packed BEACON_BUFFER, *PBEACON_BUFFER; void vDMA0_tx_80211(struct vnt_private *, struct sk_buff *skb); int nsDMA_tx_packet(struct vnt_private *, u32 uDMAIdx, struct sk_buff *skb);