diff options
author | Johannes Berg <johannes@sipsolutions.net> | 2009-04-21 01:36:59 +0200 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-04-21 16:43:33 -0400 |
commit | d1bcb9f1273adee6d2ce5edf84f19409a5cc31b9 (patch) | |
tree | 28f9aea8fae6c4835acd1be486775853417ec181 /net/mac80211 | |
parent | 7d42081a271bd8a82f2100524085c4f029e47717 (diff) | |
download | linux-d1bcb9f1273adee6d2ce5edf84f19409a5cc31b9.tar.gz linux-d1bcb9f1273adee6d2ce5edf84f19409a5cc31b9.tar.bz2 linux-d1bcb9f1273adee6d2ce5edf84f19409a5cc31b9.zip |
mac80211: fix alignment calculation bug
When checking whether or not a given frame needs to be
moved to be properly aligned to a 4-byte boundary, we
use & 4 which wasn't intended, this code should check
the lowest two bits.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211')
-rw-r--r-- | net/mac80211/rx.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c index 5fa7aedd90ed..9776f73c51ad 100644 --- a/net/mac80211/rx.c +++ b/net/mac80211/rx.c @@ -1397,7 +1397,7 @@ ieee80211_deliver_skb(struct ieee80211_rx_data *rx) * mac80211. That also explains the __skb_push() * below. */ - align = (unsigned long)skb->data & 4; + align = (unsigned long)skb->data & 3; if (align) { if (WARN_ON(skb_headroom(skb) < 3)) { dev_kfree_skb(skb); |