aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211/scan.c
diff options
context:
space:
mode:
authorStanislaw Gruszka <sgruszka@redhat.com>2012-12-20 14:41:18 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-02-14 10:47:33 -0800
commit55f40ea95452350c5bab3e84a561ee83becabd20 (patch)
tree56916cb5bda2a212c6622d81dbc2bac5535ef0e0 /net/mac80211/scan.c
parent4d973b29535f5e699da399786b41d2db25bb4b2d (diff)
downloadkernel_samsung_smdk4412-55f40ea95452350c5bab3e84a561ee83becabd20.zip
kernel_samsung_smdk4412-55f40ea95452350c5bab3e84a561ee83becabd20.tar.gz
kernel_samsung_smdk4412-55f40ea95452350c5bab3e84a561ee83becabd20.tar.bz2
mac80211: synchronize scan off/on-channel and PS states
commit aacde9ee45225f7e0b90960f479aef83c66bfdc0 upstream. Since: commit b23b025fe246f3acc2988eb6d400df34c27cb8ae Author: Ben Greear <greearb@candelatech.com> Date: Fri Feb 4 11:54:17 2011 -0800 mac80211: Optimize scans on current operating channel. we do not disable PS while going back to operational channel (on ieee80211_scan_state_suspend) and deffer that until scan finish. But since we are allowed to send frames, we can send a frame to AP without PM bit set, so disable PS on AP side. Then when we switch to off-channel (in ieee80211_scan_state_resume) we do not enable PS. Hence we are off-channel with PS disabled, frames are not buffered by AP. To fix remove offchannel_ps_disable argument and always enable PS when going off-channel and disable it when going on-channel, like it was before. Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com> Tested-by: Seth Forshee <seth.forshee@canonical.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: CAI Qian <caiqian@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net/mac80211/scan.c')
-rw-r--r--net/mac80211/scan.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/net/mac80211/scan.c b/net/mac80211/scan.c
index 669d2e3..7c75741 100644
--- a/net/mac80211/scan.c
+++ b/net/mac80211/scan.c
@@ -314,7 +314,7 @@ static void __ieee80211_scan_completed(struct ieee80211_hw *hw, bool aborted,
if (on_oper_chan2 && (on_oper_chan != on_oper_chan2))
enable_beacons = true;
- ieee80211_offchannel_return(local, enable_beacons, true);
+ ieee80211_offchannel_return(local, enable_beacons);
}
ieee80211_recalc_idle(local);
@@ -563,7 +563,7 @@ static void ieee80211_scan_state_leave_oper_channel(struct ieee80211_local *loca
/* PS will already be in off-channel mode,
* we do that once at the beginning of scanning.
*/
- ieee80211_offchannel_stop_vifs(local, false);
+ ieee80211_offchannel_stop_vifs(local);
/*
* What if the nullfunc frames didn't arrive?
@@ -594,7 +594,7 @@ static void ieee80211_scan_state_enter_oper_channel(struct ieee80211_local *loca
* in off-channel state..will put that back
* on-channel at the end of scanning.
*/
- ieee80211_offchannel_return(local, true, false);
+ ieee80211_offchannel_return(local, true);
*next_delay = HZ / 5;
local->next_scan_state = SCAN_DECISION;