diff options
author | matthieu castet <castet.matthieu@free.fr> | 2009-06-04 22:16:18 +0200 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-06-10 13:27:53 -0400 |
commit | dacb6f1d8fa5200efc4e609fe63a750b960993b6 (patch) | |
tree | aa6be0dbf67ec8b439655441d3bcdae2eb13b320 /net | |
parent | b52a033c2c501a8015df3727a4bd73389ccb1641 (diff) | |
download | kernel_samsung_crespo-dacb6f1d8fa5200efc4e609fe63a750b960993b6.zip kernel_samsung_crespo-dacb6f1d8fa5200efc4e609fe63a750b960993b6.tar.gz kernel_samsung_crespo-dacb6f1d8fa5200efc4e609fe63a750b960993b6.tar.bz2 |
mac80211 : fix unaligned rx skb
mac80211 is checking is the skb is aligned on 32 bit boundary.
But it is checking against ethernet header, whereas Linux expect IP
header aligned. And ethernet ether size is 6*2+2=14, so aligning
ethernet header make IP header unaligned.
Signed-off-by: Matthieu CASTET <castet.matthieu@free.fr>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net')
-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 6a9b8e6..7541251 100644 --- a/net/mac80211/rx.c +++ b/net/mac80211/rx.c @@ -1335,7 +1335,7 @@ ieee80211_deliver_skb(struct ieee80211_rx_data *rx) * mac80211. That also explains the __skb_push() * below. */ - align = (unsigned long)skb->data & 3; + align = ((unsigned long)(skb->data + sizeof(struct ethhdr))) & 3; if (align) { if (WARN_ON(skb_headroom(skb) < 3)) { dev_kfree_skb(skb); |