summaryrefslogtreecommitdiffstats
path: root/net/mac80211/cfg.c
diff options
context:
space:
mode:
authorJason Young2011-03-11 01:43:19 +0100
committerJohn W. Linville2011-03-11 20:15:37 +0100
commit808118cb41dfe12a1ac0e35515ac4d91b170bdf9 (patch)
tree98939cd9a6e66bcd70597ba33fdf071914e109ac /net/mac80211/cfg.c
parentlibertas: fix write past end of array in mesh_id_get() (diff)
downloadkernel-qcow2-linux-808118cb41dfe12a1ac0e35515ac4d91b170bdf9.tar.gz
kernel-qcow2-linux-808118cb41dfe12a1ac0e35515ac4d91b170bdf9.tar.xz
kernel-qcow2-linux-808118cb41dfe12a1ac0e35515ac4d91b170bdf9.zip
mac80211: do not enable ps if 802.1x controlled port is unblocked
If dynamic_ps is disabled, enabling power save before the 4-way handshake completes may delay the station from being authorized to send/receive traffic, i.e. increase roaming times. It also may result in a failed 4-way handshake depending on the AP's timing requirements and beacon interval, and the station's listen interval. To fix this, prevent power save from being enabled while the station isn't authorized and recalculate power save whenever the station's authorized state changes. Signed-off-by: Jason Young <a.young.jason@gmail.com> Acked-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/cfg.c')
-rw-r--r--net/mac80211/cfg.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c
index 7b701dcddb50..11866b42f1ed 100644
--- a/net/mac80211/cfg.c
+++ b/net/mac80211/cfg.c
@@ -834,6 +834,10 @@ static int ieee80211_change_station(struct wiphy *wiphy,
rcu_read_unlock();
+ if (sdata->vif.type == NL80211_IFTYPE_STATION &&
+ params->sta_flags_mask & BIT(NL80211_STA_FLAG_AUTHORIZED))
+ ieee80211_recalc_ps(local, -1);
+
return 0;
}