aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211
diff options
context:
space:
mode:
authorJanusz Dziedzic <janusz.dziedzic@tieto.com>2013-11-05 08:48:46 -0500
committerJohannes Berg <johannes.berg@intel.com>2013-11-25 10:50:03 -0500
commit84a3d1c97d024acd1d27ebbc10cb95784b11f4e7 (patch)
tree844e6c70bc2b191b3f1095850842b0175e885fe4 /net/mac80211
parent1fe4517cebc35ef900fa483d19c3090681f3c7bc (diff)
mac80211: DFS setup chandef for radar_event correctly
Setup chandef for radar event correctly, before we will clear this in ieee80211_dfs_cac_cancel() function. Without this patch mac80211 will report wrong channel width in case we will get radar event during active CAC. Signed-off-by: Janusz Dziedzic <janusz.dziedzic@tieto.com> Reviewed-by: Luis R. Rodriguez <mcgrof@do-not-panic.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211')
-rw-r--r--net/mac80211/util.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/net/mac80211/util.c b/net/mac80211/util.c
index 592a18171f95..e9ce36d32ef5 100644
--- a/net/mac80211/util.c
+++ b/net/mac80211/util.c
@@ -2278,17 +2278,15 @@ void ieee80211_dfs_radar_detected_work(struct work_struct *work)
2278{ 2278{
2279 struct ieee80211_local *local = 2279 struct ieee80211_local *local =
2280 container_of(work, struct ieee80211_local, radar_detected_work); 2280 container_of(work, struct ieee80211_local, radar_detected_work);
2281 struct cfg80211_chan_def chandef; 2281 struct cfg80211_chan_def chandef = local->hw.conf.chandef;
2282 2282
2283 ieee80211_dfs_cac_cancel(local); 2283 ieee80211_dfs_cac_cancel(local);
2284 2284
2285 if (local->use_chanctx) 2285 if (local->use_chanctx)
2286 /* currently not handled */ 2286 /* currently not handled */
2287 WARN_ON(1); 2287 WARN_ON(1);
2288 else { 2288 else
2289 chandef = local->hw.conf.chandef;
2290 cfg80211_radar_event(local->hw.wiphy, &chandef, GFP_KERNEL); 2289 cfg80211_radar_event(local->hw.wiphy, &chandef, GFP_KERNEL);
2291 }
2292} 2290}
2293 2291
2294void ieee80211_radar_detected(struct ieee80211_hw *hw) 2292void ieee80211_radar_detected(struct ieee80211_hw *hw)