Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

hostap: pad the skb->cb usage in lieu of a proper fix

Like mac80211 did, this driver makes 'clever' use of skb->cb to pass
information along with an skb as it is requeued from the virtual device
to the physical wireless device. Unfortunately, that trick no longer
works...

Unlike mac80211, code complexity and driver apathy makes this hack
the best option we have in the short run. Hopefully someone will
eventually be motivated to code a proper fix before all the effected
hardware dies.

(Above text by me. Johannes officially disavows all knowledge of this
hack. -- JWL)

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Cc: stable@kernel.org
Signed-off-by: John W. Linville <linville@tuxdriver.com>

authored by

Johannes Berg and committed by
John W. Linville
f7cd1686 f3c76918

+4 -1
+4 -1
drivers/net/wireless/hostap/hostap_wlan.h
··· 918 918 919 919 /* 920 920 * TX meta data - stored in skb->cb buffer, so this must not be increased over 921 - * the 40-byte limit 921 + * the 48-byte limit. 922 + * THE PADDING THIS STARTS WITH IS A HORRIBLE HACK THAT SHOULD NOT LIVE 923 + * TO SEE THE DAY. 922 924 */ 923 925 struct hostap_skb_tx_data { 926 + unsigned int __padding_for_default_qdiscs; 924 927 u32 magic; /* HOSTAP_SKB_TX_DATA_MAGIC */ 925 928 u8 rate; /* transmit rate */ 926 929 #define HOSTAP_TX_FLAGS_WDS BIT(0)