diff mbox series

cfg80211: fix dfs channels remain DFS_AVAILABLE after ch_switch

Message ID 20190729060024.5660-1-michael.vassernis@tandemg.com (mailing list archive)
State Accepted
Delegated to: Johannes Berg
Headers show
Series cfg80211: fix dfs channels remain DFS_AVAILABLE after ch_switch | expand

Commit Message

Michael Vassernis July 29, 2019, 6:01 a.m. UTC
Depending on the regulatory domain, leaving a DFS channel requires
a new CAC to be performed when returning back to that channel.
If needed, update dfs states after a driver channel switch.

Signed-off-by: Michael Vassernis <michael.vassernis@tandemg.com>
---
 net/wireless/nl80211.c | 2 ++
 1 file changed, 2 insertions(+)
diff mbox series

Patch

diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index fc83dd179c1a..b8c51750ff32 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -16094,6 +16094,8 @@  void cfg80211_ch_switch_notify(struct net_device *dev,
 	    !WARN_ON(!wdev->current_bss))
 		wdev->current_bss->pub.channel = chandef->chan;
 
+	cfg80211_sched_dfs_chan_update(rdev);
+
 	nl80211_ch_switch_notify(rdev, dev, chandef, GFP_KERNEL,
 				 NL80211_CMD_CH_SWITCH_NOTIFY, 0);
 }