diff options
Diffstat (limited to 'net/mac80211/sta_info.c')
-rw-r--r-- | net/mac80211/sta_info.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/net/mac80211/sta_info.c b/net/mac80211/sta_info.c index 0a4e4c04db89..d2eb64e12353 100644 --- a/net/mac80211/sta_info.c +++ b/net/mac80211/sta_info.c | |||
@@ -117,8 +117,8 @@ static void free_sta_work(struct work_struct *wk) | |||
117 | 117 | ||
118 | for (ac = 0; ac < IEEE80211_NUM_ACS; ac++) { | 118 | for (ac = 0; ac < IEEE80211_NUM_ACS; ac++) { |
119 | local->total_ps_buffered -= skb_queue_len(&sta->ps_tx_buf[ac]); | 119 | local->total_ps_buffered -= skb_queue_len(&sta->ps_tx_buf[ac]); |
120 | __skb_queue_purge(&sta->ps_tx_buf[ac]); | 120 | ieee80211_purge_tx_queue(&local->hw, &sta->ps_tx_buf[ac]); |
121 | __skb_queue_purge(&sta->tx_filtered[ac]); | 121 | ieee80211_purge_tx_queue(&local->hw, &sta->tx_filtered[ac]); |
122 | } | 122 | } |
123 | 123 | ||
124 | #ifdef CONFIG_MAC80211_MESH | 124 | #ifdef CONFIG_MAC80211_MESH |
@@ -141,7 +141,7 @@ static void free_sta_work(struct work_struct *wk) | |||
141 | tid_tx = rcu_dereference_raw(sta->ampdu_mlme.tid_tx[i]); | 141 | tid_tx = rcu_dereference_raw(sta->ampdu_mlme.tid_tx[i]); |
142 | if (!tid_tx) | 142 | if (!tid_tx) |
143 | continue; | 143 | continue; |
144 | __skb_queue_purge(&tid_tx->pending); | 144 | ieee80211_purge_tx_queue(&local->hw, &tid_tx->pending); |
145 | kfree(tid_tx); | 145 | kfree(tid_tx); |
146 | } | 146 | } |
147 | 147 | ||
@@ -961,6 +961,7 @@ void ieee80211_sta_ps_deliver_wakeup(struct sta_info *sta) | |||
961 | struct ieee80211_local *local = sdata->local; | 961 | struct ieee80211_local *local = sdata->local; |
962 | struct sk_buff_head pending; | 962 | struct sk_buff_head pending; |
963 | int filtered = 0, buffered = 0, ac; | 963 | int filtered = 0, buffered = 0, ac; |
964 | unsigned long flags; | ||
964 | 965 | ||
965 | clear_sta_flag(sta, WLAN_STA_SP); | 966 | clear_sta_flag(sta, WLAN_STA_SP); |
966 | 967 | ||
@@ -976,12 +977,16 @@ void ieee80211_sta_ps_deliver_wakeup(struct sta_info *sta) | |||
976 | for (ac = 0; ac < IEEE80211_NUM_ACS; ac++) { | 977 | for (ac = 0; ac < IEEE80211_NUM_ACS; ac++) { |
977 | int count = skb_queue_len(&pending), tmp; | 978 | int count = skb_queue_len(&pending), tmp; |
978 | 979 | ||
980 | spin_lock_irqsave(&sta->tx_filtered[ac].lock, flags); | ||
979 | skb_queue_splice_tail_init(&sta->tx_filtered[ac], &pending); | 981 | skb_queue_splice_tail_init(&sta->tx_filtered[ac], &pending); |
982 | spin_unlock_irqrestore(&sta->tx_filtered[ac].lock, flags); | ||
980 | tmp = skb_queue_len(&pending); | 983 | tmp = skb_queue_len(&pending); |
981 | filtered += tmp - count; | 984 | filtered += tmp - count; |
982 | count = tmp; | 985 | count = tmp; |
983 | 986 | ||
987 | spin_lock_irqsave(&sta->ps_tx_buf[ac].lock, flags); | ||
984 | skb_queue_splice_tail_init(&sta->ps_tx_buf[ac], &pending); | 988 | skb_queue_splice_tail_init(&sta->ps_tx_buf[ac], &pending); |
989 | spin_unlock_irqrestore(&sta->ps_tx_buf[ac].lock, flags); | ||
985 | tmp = skb_queue_len(&pending); | 990 | tmp = skb_queue_len(&pending); |
986 | buffered += tmp - count; | 991 | buffered += tmp - count; |
987 | } | 992 | } |