From: Hennerich, Michael Date: Tue, 6 Feb 2007 00:41:35 +0000 (-0800) Subject: fix unaligned exception in /drivers/net/wireless/orinoco.c X-Git-Tag: v2.6.21-rc1~92^2~31^2~9 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=dde6d43d060bf0e0f38c66f76908e460db3bf0d8;p=linux-2.6 fix unaligned exception in /drivers/net/wireless/orinoco.c Prevent an unaligned exception to occur. (GCC 4.1) tmp is defined as char pointer while it is later accessed as short. Cc: Jean Tourrilhes Cc: John W. Linville Cc: Jeff Garzik Signed-off-by: Andrew Morton Signed-off-by: Jeff Garzik --- diff --git a/drivers/net/wireless/orinoco.c b/drivers/net/wireless/orinoco.c index 936c888e03..2a65bb93de 100644 --- a/drivers/net/wireless/orinoco.c +++ b/drivers/net/wireless/orinoco.c @@ -2059,7 +2059,7 @@ static int determine_firmware(struct net_device *dev) int err; struct comp_id nic_id, sta_id; unsigned int firmver; - char tmp[SYMBOL_MAX_VER_LEN+1]; + char tmp[SYMBOL_MAX_VER_LEN+1] __attribute__((aligned(2))); /* Get the hardware version */ err = HERMES_READ_RECORD(hw, USER_BAP, HERMES_RID_NICID, &nic_id);