aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorEmmanuel Grumbach <emmanuel.grumbach@intel.com>2016-03-17 10:51:42 -0400
committerJohannes Berg <johannes.berg@intel.com>2016-04-05 05:33:49 -0400
commitf6d4671a08810ff5111099dd1febe57e7eb9ba59 (patch)
tree6de26dd2c4395d0915a8431ff6d43def09d21435 /net
parent4b559ec0bfc3a9f41a127cea6964f38b2b4bb323 (diff)
mac80211: close the SP when we enqueue frames during the SP
Since we enqueued the frame that was supposed to be sent during the SP, and that frame may very well cary the IEEE80211_TX_STATUS_EOSP bit, we may never close the SP (WLAN_STA_SP will never be cleared). If that happens, we will not open any new SP and will never respond to any poll frame from the client. Clear WLAN_STA_SP manually if a frame that was polled during the SP is queued because of a starting A-MPDU session. The client may not see the EOSP bit, but it will at least be able to poll new frames in another SP. Reported-by: Alesya Shapira <alesya.shapira@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> [remove erroneous comment] Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net')
-rw-r--r--net/mac80211/tx.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c
index 6ce686b96ec0..21f6602395f7 100644
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -1116,6 +1116,12 @@ static bool ieee80211_tx_prep_agg(struct ieee80211_tx_data *tx,
1116 reset_agg_timer = true; 1116 reset_agg_timer = true;
1117 } else { 1117 } else {
1118 queued = true; 1118 queued = true;
1119 if (info->flags & IEEE80211_TX_CTL_NO_PS_BUFFER) {
1120 clear_sta_flag(tx->sta, WLAN_STA_SP);
1121 ps_dbg(tx->sta->sdata,
1122 "STA %pM aid %d: SP frame queued, close the SP w/o telling the peer\n",
1123 tx->sta->sta.addr, tx->sta->sta.aid);
1124 }
1119 info->control.vif = &tx->sdata->vif; 1125 info->control.vif = &tx->sdata->vif;
1120 info->flags |= IEEE80211_TX_INTFL_NEED_TXPROCESSING; 1126 info->flags |= IEEE80211_TX_INTFL_NEED_TXPROCESSING;
1121 info->flags &= ~IEEE80211_TX_TEMPORARY_FLAGS; 1127 info->flags &= ~IEEE80211_TX_TEMPORARY_FLAGS;