summaryrefslogtreecommitdiffstats
path: root/net/mac80211/scan.c
diff options
context:
space:
mode:
authorEliad Peller <eliad@wizery.com>2015-01-07 17:50:09 +0200
committerJohannes Berg <johannes.berg@intel.com>2015-01-14 09:37:06 +0100
commit5cbc95a749c5f3b238af0953881edede9bfe5bf6 (patch)
tree4bd05d244a56723b38bfafcba8eed0875249027e /net/mac80211/scan.c
parent50075892ba30c4c19c41235b5308ee5a1e2125d7 (diff)
downloadlinux-5cbc95a749c5f3b238af0953881edede9bfe5bf6.tar.gz
linux-5cbc95a749c5f3b238af0953881edede9bfe5bf6.tar.bz2
linux-5cbc95a749c5f3b238af0953881edede9bfe5bf6.zip
mac80211: remove local->radar_detect_enabled
local->radar_detect_enabled should tell whether radar_detect is enabled on any interface belonging to local. However, it's not getting updated correctly in many cases (actually, when testing with hwsim it's never been set, even when the dfs master is beaconing). Instead of handling all the corner cases (e.g. channel switch), simply check whether radar detection is enabled only when needed, instead of caching the result. Signed-off-by: Eliad Peller <eliad@wizery.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211/scan.c')
-rw-r--r--net/mac80211/scan.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/mac80211/scan.c b/net/mac80211/scan.c
index 844fb5f7910e..b0320bb20ab8 100644
--- a/net/mac80211/scan.c
+++ b/net/mac80211/scan.c
@@ -432,7 +432,7 @@ static int ieee80211_start_sw_scan(struct ieee80211_local *local,
static bool ieee80211_can_scan(struct ieee80211_local *local,
struct ieee80211_sub_if_data *sdata)
{
- if (local->radar_detect_enabled)
+ if (ieee80211_is_radar_required(local))
return false;
if (!list_empty(&local->roc_list))