diff options
-rw-r--r-- | net/mac80211/cfg.c | 2 | ||||
-rw-r--r-- | net/mac80211/chan.c | 5 | ||||
-rw-r--r-- | net/mac80211/ieee80211_i.h | 3 | ||||
-rw-r--r-- | net/mac80211/scan.c | 2 |
4 files changed, 5 insertions, 7 deletions
diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c index 9ccecb405ede..fd6860d7f557 100644 --- a/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c | |||
@@ -2557,7 +2557,7 @@ static int ieee80211_start_roc_work(struct ieee80211_local *local, | |||
2557 | 2557 | ||
2558 | /* if there's one pending or we're scanning, queue this one */ | 2558 | /* if there's one pending or we're scanning, queue this one */ |
2559 | if (!list_empty(&local->roc_list) || | 2559 | if (!list_empty(&local->roc_list) || |
2560 | local->scanning || local->radar_detect_enabled) | 2560 | local->scanning || ieee80211_is_radar_required(local)) |
2561 | goto out_check_combine; | 2561 | goto out_check_combine; |
2562 | 2562 | ||
2563 | /* if not HW assist, just queue & schedule work */ | 2563 | /* if not HW assist, just queue & schedule work */ |
diff --git a/net/mac80211/chan.c b/net/mac80211/chan.c index da1c12c34487..92c721dbd5af 100644 --- a/net/mac80211/chan.c +++ b/net/mac80211/chan.c | |||
@@ -388,7 +388,7 @@ ieee80211_find_chanctx(struct ieee80211_local *local, | |||
388 | return NULL; | 388 | return NULL; |
389 | } | 389 | } |
390 | 390 | ||
391 | static bool ieee80211_is_radar_required(struct ieee80211_local *local) | 391 | bool ieee80211_is_radar_required(struct ieee80211_local *local) |
392 | { | 392 | { |
393 | struct ieee80211_sub_if_data *sdata; | 393 | struct ieee80211_sub_if_data *sdata; |
394 | 394 | ||
@@ -567,7 +567,7 @@ static void ieee80211_recalc_radar_chanctx(struct ieee80211_local *local, | |||
567 | bool radar_enabled; | 567 | bool radar_enabled; |
568 | 568 | ||
569 | lockdep_assert_held(&local->chanctx_mtx); | 569 | lockdep_assert_held(&local->chanctx_mtx); |
570 | /* for setting local->radar_detect_enabled */ | 570 | /* for ieee80211_is_radar_required */ |
571 | lockdep_assert_held(&local->mtx); | 571 | lockdep_assert_held(&local->mtx); |
572 | 572 | ||
573 | radar_enabled = ieee80211_is_radar_required(local); | 573 | radar_enabled = ieee80211_is_radar_required(local); |
@@ -576,7 +576,6 @@ static void ieee80211_recalc_radar_chanctx(struct ieee80211_local *local, | |||
576 | return; | 576 | return; |
577 | 577 | ||
578 | chanctx->conf.radar_enabled = radar_enabled; | 578 | chanctx->conf.radar_enabled = radar_enabled; |
579 | local->radar_detect_enabled = chanctx->conf.radar_enabled; | ||
580 | 579 | ||
581 | if (!local->use_chanctx) { | 580 | if (!local->use_chanctx) { |
582 | local->hw.conf.radar_enabled = chanctx->conf.radar_enabled; | 581 | local->hw.conf.radar_enabled = chanctx->conf.radar_enabled; |
diff --git a/net/mac80211/ieee80211_i.h b/net/mac80211/ieee80211_i.h index 91878ef5069a..156ea79e0157 100644 --- a/net/mac80211/ieee80211_i.h +++ b/net/mac80211/ieee80211_i.h | |||
@@ -1168,8 +1168,6 @@ struct ieee80211_local { | |||
1168 | /* wowlan is enabled -- don't reconfig on resume */ | 1168 | /* wowlan is enabled -- don't reconfig on resume */ |
1169 | bool wowlan; | 1169 | bool wowlan; |
1170 | 1170 | ||
1171 | /* DFS/radar detection is enabled */ | ||
1172 | bool radar_detect_enabled; | ||
1173 | struct work_struct radar_detected_work; | 1171 | struct work_struct radar_detected_work; |
1174 | 1172 | ||
1175 | /* number of RX chains the hardware has */ | 1173 | /* number of RX chains the hardware has */ |
@@ -1982,6 +1980,7 @@ void ieee80211_recalc_smps_chanctx(struct ieee80211_local *local, | |||
1982 | struct ieee80211_chanctx *chanctx); | 1980 | struct ieee80211_chanctx *chanctx); |
1983 | void ieee80211_recalc_chanctx_min_def(struct ieee80211_local *local, | 1981 | void ieee80211_recalc_chanctx_min_def(struct ieee80211_local *local, |
1984 | struct ieee80211_chanctx *ctx); | 1982 | struct ieee80211_chanctx *ctx); |
1983 | bool ieee80211_is_radar_required(struct ieee80211_local *local); | ||
1985 | 1984 | ||
1986 | void ieee80211_dfs_cac_timer(unsigned long data); | 1985 | void ieee80211_dfs_cac_timer(unsigned long data); |
1987 | void ieee80211_dfs_cac_timer_work(struct work_struct *work); | 1986 | void ieee80211_dfs_cac_timer_work(struct work_struct *work); |
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, | |||
432 | static bool ieee80211_can_scan(struct ieee80211_local *local, | 432 | static bool ieee80211_can_scan(struct ieee80211_local *local, |
433 | struct ieee80211_sub_if_data *sdata) | 433 | struct ieee80211_sub_if_data *sdata) |
434 | { | 434 | { |
435 | if (local->radar_detect_enabled) | 435 | if (ieee80211_is_radar_required(local)) |
436 | return false; | 436 | return false; |
437 | 437 | ||
438 | if (!list_empty(&local->roc_list)) | 438 | if (!list_empty(&local->roc_list)) |