summaryrefslogtreecommitdiffstats
path: root/net/mac80211
diff options
context:
space:
mode:
authorJohannes Berg <johannes.berg@intel.com>2010-08-25 14:47:38 +0200
committerJohn W. Linville <linville@tuxdriver.com>2010-08-30 16:02:34 -0400
commit071249b1d501b1f31a6b1af3fbcbe03158a84e5c (patch)
treef25daa4a50718b42ee8597a0b6b8c3ca86be7383 /net/mac80211
parentf880c2050f30b23c9b6f80028c09f76e693bf309 (diff)
downloadtalos-op-linux-071249b1d501b1f31a6b1af3fbcbe03158a84e5c.tar.gz
talos-op-linux-071249b1d501b1f31a6b1af3fbcbe03158a84e5c.zip
mac80211: delete work timer
The new workqueue changes helped me find this bug that's been lingering since the changes to the work processing in mac80211 -- the work timer is never deleted properly. Do that to avoid having it fire after all data structures have been freed. It can't be re-armed because all it will do, if running, is schedule the work, but that gets flushed later and won't have anything to do since all work items are gone by now (by way of interface removal). Cc: stable@kernel.org [2.6.34+] Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211')
-rw-r--r--net/mac80211/main.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/net/mac80211/main.c b/net/mac80211/main.c
index 798a91b100cc..ded5c3843e06 100644
--- a/net/mac80211/main.c
+++ b/net/mac80211/main.c
@@ -732,6 +732,12 @@ void ieee80211_unregister_hw(struct ieee80211_hw *hw)
rtnl_unlock();
+ /*
+ * Now all work items will be gone, but the
+ * timer might still be armed, so delete it
+ */
+ del_timer_sync(&local->work_timer);
+
cancel_work_sync(&local->reconfig_filter);
ieee80211_clear_tx_pending(local);
OpenPOWER on IntegriCloud