From: Felix Fietkau Date: Thu, 1 Mar 2012 10:23:37 +0000 (+0100) Subject: mac80211: use 16 bit alignment for the if_ibss bssid field X-Git-Tag: v3.4-rc1~177^2~108^2~170 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4d196e4b2ffd734393b54f351507462f19d737b5;p=platform%2Fkernel%2Flinux-3.10.git mac80211: use 16 bit alignment for the if_ibss bssid field Several MAC address comparison functions assume 16 bit alignment for pointers passed to them. Since the addition of the control_port field, alignment for the IBSS bssid was off by one, causing a severe performance hit on architectures without efficient unaligned access (e.g. MIPS). Signed-off-by: Felix Fietkau Acked-by: Johannes Berg Signed-off-by: John W. Linville --- diff --git a/net/mac80211/ieee80211_i.h b/net/mac80211/ieee80211_i.h index cee0c74..c413058 100644 --- a/net/mac80211/ieee80211_i.h +++ b/net/mac80211/ieee80211_i.h @@ -480,7 +480,7 @@ struct ieee80211_if_ibss { bool control_port; - u8 bssid[ETH_ALEN]; + u8 bssid[ETH_ALEN] __aligned(2); u8 ssid[IEEE80211_MAX_SSID_LEN]; u8 ssid_len, ie_len; u8 *ie;