summaryrefslogtreecommitdiff
path: root/net/mac80211/status.c
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2012-11-10 06:44:14 +0400
committerJohannes Berg <johannes.berg@intel.com>2012-11-11 00:26:28 +0400
commit1f98ab7fef48a2968f37f422c256c9fbd978c3f0 (patch)
tree69f0c49312c489063d02da10ac1f39490a585334 /net/mac80211/status.c
parent20f544eea03db4b498942558b882d463ce575c3e (diff)
downloadlinux-1f98ab7fef48a2968f37f422c256c9fbd978c3f0.tar.xz
mac80211: call skb_dequeue/ieee80211_free_txskb instead of __skb_queue_purge
Fixes more wifi status skb leaks, leading to hostapd/wpa_supplicant hangs. Signed-off-by: Felix Fietkau <nbd@openwrt.org> Cc: stable@vger.kernel.org Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211/status.c')
-rw-r--r--net/mac80211/status.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/net/mac80211/status.c b/net/mac80211/status.c
index 3af0cc4130f1..101eb88a2b78 100644
--- a/net/mac80211/status.c
+++ b/net/mac80211/status.c
@@ -668,3 +668,12 @@ void ieee80211_free_txskb(struct ieee80211_hw *hw, struct sk_buff *skb)
dev_kfree_skb_any(skb);
}
EXPORT_SYMBOL(ieee80211_free_txskb);
+
+void ieee80211_purge_tx_queue(struct ieee80211_hw *hw,
+ struct sk_buff_head *skbs)
+{
+ struct sk_buff *skb;
+
+ while ((skb = __skb_dequeue(skbs)))
+ ieee80211_free_txskb(hw, skb);
+}