Skip to contentSkip to conversation

b43: Fix PIO skb clobber

PATCH New Michael Buesch 1 participant 1 message Jun 24, 2008 Networking drivers (wireless)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 b43: Fix PIO skb clobber

This fixes a clobber of the skb that was introduced by the tx_control->cb conversion patches.
This bug causes a crash when the skb destructor is invoked. That happens on skb_orphan or skb_kfree.

---

John, please apply this bugfix to 2.6.27, as the bug is not present in 2.6.26.

drivers/net/wireless/b43/pio.c +1 -1
Index: wireless-testing/drivers/net/wireless/b43/pio.c
===================================================================
@@ -583,13 +583,13 @@ void b43_pio_handle_txstatus(struct b43_
 	if (unlikely(!q))
 		return;
 	B43_WARN_ON(!pack);
 
 	spin_lock(&q->lock); /* IRQs are already disabled. */
 
-	info = (void *)pack->skb;
+	info = IEEE80211_SKB_CB(pack->skb);
 	memset(&info->status, 0, sizeof(info->status));
 
 	b43_fill_txstatus_report(info, status);
 
 	total_len = pack->skb->len + b43_txhdr_size(dev);
 	total_len = roundup(total_len, 4);