From: Wu, Bryan Date: Thu, 26 Apr 2007 07:38:01 +0000 (-0700) Subject: USB gadget rndis: fix struct rndis_packet_msg_type unaligned bug X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=178398dca00b276aaa1aded7cded89921f710365;p=GitHub%2Fmt8127%2Fandroid_kernel_alcatel_ttab.git USB gadget rndis: fix struct rndis_packet_msg_type unaligned bug skb_push function may return a pointer which is not aligned as required by struct rndis_packet_msg_type. Using attribute trick to fix this bug. Signed-off-by: Roy Huang Signed-off-by: Jie Zhang Signed-off-by: Bryan Wu Cc: David Brownell Signed-off-by: Andrew Morton Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/usb/gadget/rndis.h b/drivers/usb/gadget/rndis.h index 4c3c7259f019..397b149f3ca7 100644 --- a/drivers/usb/gadget/rndis.h +++ b/drivers/usb/gadget/rndis.h @@ -195,7 +195,7 @@ struct rndis_packet_msg_type __le32 PerPacketInfoLength; __le32 VcHandle; __le32 Reserved; -}; +} __attribute__ ((packed)); struct rndis_config_parameter {