mac80211: Replace {sw, hw}_scanning variables with a bitfield
Use a bitfield to store the current scan mode instead of two boolean
variables {sw,hw}_scanning. This patch does not introduce functional
changes but allows us to enhance the scan flags later (for example
for background scanning).
Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
committed by
John W. Linville
parent
2fb3f028a9
commit
fbe9c429f1
@@ -518,7 +518,7 @@ static int ieee80211_stop(struct net_device *dev)
|
||||
* the scan_sdata is NULL already don't send out a
|
||||
* scan event to userspace -- the scan is incomplete.
|
||||
*/
|
||||
if (local->sw_scanning)
|
||||
if (test_bit(SCAN_SW_SCANNING, &local->scanning))
|
||||
ieee80211_scan_completed(&local->hw, true);
|
||||
}
|
||||
|
||||
@@ -920,7 +920,7 @@ u32 __ieee80211_recalc_idle(struct ieee80211_local *local)
|
||||
struct ieee80211_sub_if_data *sdata;
|
||||
int count = 0;
|
||||
|
||||
if (local->hw_scanning || local->sw_scanning)
|
||||
if (local->scanning)
|
||||
return ieee80211_idle_off(local, "scanning");
|
||||
|
||||
list_for_each_entry(sdata, &local->interfaces, list) {
|
||||
|
||||
Reference in New Issue
Block a user