summaryrefslogtreecommitdiffstats
path: root/net/mac80211/util.c
diff options
context:
space:
mode:
authorEliad Peller <eliad@wizery.com>2015-12-14 16:26:57 +0200
committerJohannes Berg <johannes.berg@intel.com>2016-01-14 11:10:14 +0100
commit470f4d613b51806e15e055428234a04a99f076fc (patch)
treeda223fd2bd22e92c56da22c923da87ffa4707769 /net/mac80211/util.c
parentc3826807bbb3de693208da4ecb9c9602de16c616 (diff)
downloadlinux-stable-470f4d613b51806e15e055428234a04a99f076fc.tar.gz
linux-stable-470f4d613b51806e15e055428234a04a99f076fc.tar.bz2
linux-stable-470f4d613b51806e15e055428234a04a99f076fc.zip
mac80211: avoid ROC during hw restart
Defer ROC requests during hw restart, as the driver might not be fully configured in this stage (e.g. channel contexts were not added yet) Signed-off-by: Eliad Peller <eliadx.peller@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211/util.c')
-rw-r--r--net/mac80211/util.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/net/mac80211/util.c b/net/mac80211/util.c
index 3943d4bf289c..4f6e0b79ef69 100644
--- a/net/mac80211/util.c
+++ b/net/mac80211/util.c
@@ -2051,8 +2051,15 @@ int ieee80211_reconfig(struct ieee80211_local *local)
cfg80211_sched_scan_stopped_rtnl(local->hw.wiphy);
wake_up:
- local->in_reconfig = false;
- barrier();
+ if (local->in_reconfig) {
+ local->in_reconfig = false;
+ barrier();
+
+ /* Restart deferred ROCs */
+ mutex_lock(&local->mtx);
+ ieee80211_start_next_roc(local);
+ mutex_unlock(&local->mtx);
+ }
if (local->monitors == local->open_count && local->monitors > 0)
ieee80211_add_virtual_monitor(local);