diff options
author | Ben Greear <greearb@candelatech.com> | 2011-02-04 14:54:17 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-02-04 16:30:32 -0500 |
commit | b23b025fe246f3acc2988eb6d400df34c27cb8ae (patch) | |
tree | e1c8cd163dc4dc7c603652a9e101f8381cf66fdc /net/mac80211/ieee80211_i.h | |
parent | cb8d61de2d7f074654057b2b924da1efbf625ad4 (diff) |
mac80211: Optimize scans on current operating channel.
This should decrease un-necessary flushes, on/off channel work,
and channel changes in cases where the only scanned channel is
the current operating channel.
* Removes SCAN_OFF_CHANNEL flag, uses SDATA_STATE_OFFCHANNEL
and is-scanning flags instead.
* Add helper method to determine if we are currently configured
for the operating channel.
* Do no blindly go off/on channel in work.c Instead, only call
appropriate on/off code when we really need to change channels.
Always enable offchannel-ps mode when starting work,
and disable it when we are done.
* Consolidate ieee80211_offchannel_stop_station and
ieee80211_offchannel_stop_beaconing, call it
ieee80211_offchannel_stop_vifs instead.
* Accept non-beacon frames when scanning on operating channel.
* Scan state machine optimized to minimize on/off channel
transitions. Also, when going on-channel, go ahead and
re-enable beaconing. We're going to be there for 200ms,
so seems like some useful beaconing could happen.
Always enable offchannel-ps mode when starting software
scan, and disable it when we are done.
* Grab local->mtx earlier in __ieee80211_scan_completed_finish
so that we are protected when calling hw_config(), etc.
* Pass probe-responses up the stack if scanning on local
channel, so that mlme can take a look.
Signed-off-by: Ben Greear <greearb@candelatech.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/ieee80211_i.h')
-rw-r--r-- | net/mac80211/ieee80211_i.h | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/net/mac80211/ieee80211_i.h b/net/mac80211/ieee80211_i.h index f71ed31d176a..44eea1af1553 100644 --- a/net/mac80211/ieee80211_i.h +++ b/net/mac80211/ieee80211_i.h | |||
@@ -655,8 +655,6 @@ struct tpt_led_trigger { | |||
655 | * well be on the operating channel | 655 | * well be on the operating channel |
656 | * @SCAN_HW_SCANNING: The hardware is scanning for us, we have no way to | 656 | * @SCAN_HW_SCANNING: The hardware is scanning for us, we have no way to |
657 | * determine if we are on the operating channel or not | 657 | * determine if we are on the operating channel or not |
658 | * @SCAN_OFF_CHANNEL: We're off our operating channel for scanning, | ||
659 | * gets only set in conjunction with SCAN_SW_SCANNING | ||
660 | * @SCAN_COMPLETED: Set for our scan work function when the driver reported | 658 | * @SCAN_COMPLETED: Set for our scan work function when the driver reported |
661 | * that the scan completed. | 659 | * that the scan completed. |
662 | * @SCAN_ABORTED: Set for our scan work function when the driver reported | 660 | * @SCAN_ABORTED: Set for our scan work function when the driver reported |
@@ -665,7 +663,6 @@ struct tpt_led_trigger { | |||
665 | enum { | 663 | enum { |
666 | SCAN_SW_SCANNING, | 664 | SCAN_SW_SCANNING, |
667 | SCAN_HW_SCANNING, | 665 | SCAN_HW_SCANNING, |
668 | SCAN_OFF_CHANNEL, | ||
669 | SCAN_COMPLETED, | 666 | SCAN_COMPLETED, |
670 | SCAN_ABORTED, | 667 | SCAN_ABORTED, |
671 | }; | 668 | }; |
@@ -1148,10 +1145,14 @@ void ieee80211_rx_bss_put(struct ieee80211_local *local, | |||
1148 | struct ieee80211_bss *bss); | 1145 | struct ieee80211_bss *bss); |
1149 | 1146 | ||
1150 | /* off-channel helpers */ | 1147 | /* off-channel helpers */ |
1151 | void ieee80211_offchannel_stop_beaconing(struct ieee80211_local *local); | 1148 | bool ieee80211_cfg_on_oper_channel(struct ieee80211_local *local); |
1152 | void ieee80211_offchannel_stop_station(struct ieee80211_local *local); | 1149 | void ieee80211_offchannel_enable_all_ps(struct ieee80211_local *local, |
1150 | bool tell_ap); | ||
1151 | void ieee80211_offchannel_stop_vifs(struct ieee80211_local *local, | ||
1152 | bool offchannel_ps_enable); | ||
1153 | void ieee80211_offchannel_return(struct ieee80211_local *local, | 1153 | void ieee80211_offchannel_return(struct ieee80211_local *local, |
1154 | bool enable_beaconing); | 1154 | bool enable_beaconing, |
1155 | bool offchannel_ps_disable); | ||
1155 | void ieee80211_hw_roc_setup(struct ieee80211_local *local); | 1156 | void ieee80211_hw_roc_setup(struct ieee80211_local *local); |
1156 | 1157 | ||
1157 | /* interface handling */ | 1158 | /* interface handling */ |