aboutsummaryrefslogtreecommitdiffstats
path: root/net/ieee80211/softmac/ieee80211softmac_scan.c
diff options
context:
space:
mode:
authorJohannes Berg <johannes@sipsolutions.net>2007-10-03 21:14:23 -0400
committerDavid S. Miller <davem@sunset.davemloft.net>2007-10-10 19:52:22 -0400
commit501d857ec93e797d4872d6b9b265b7472b455ddf (patch)
treef4bbdd316145573af7234960599e45592b73f8fe /net/ieee80211/softmac/ieee80211softmac_scan.c
parent05155c83d13b983ac2c5691575fd471543df31fe (diff)
[IEEE80211]: Fix softmac lockdep reports.
It seems I was actually able to hit this deadlock, on my quad G5 softmac locks up more often than not. This fixes it by using an own workqueue that can safely be flushed under RTNL. Not sure if the patch is correct with the workqueue naming. And don't think with the patch it doesn't continually lock up. It still does, just doesn't invoke lockdep warnings all the time. Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ieee80211/softmac/ieee80211softmac_scan.c')
-rw-r--r--net/ieee80211/softmac/ieee80211softmac_scan.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/net/ieee80211/softmac/ieee80211softmac_scan.c b/net/ieee80211/softmac/ieee80211softmac_scan.c
index abea3648680e..bfab8d7db88f 100644
--- a/net/ieee80211/softmac/ieee80211softmac_scan.c
+++ b/net/ieee80211/softmac/ieee80211softmac_scan.c
@@ -123,7 +123,7 @@ void ieee80211softmac_scan(struct work_struct *work)
123 spin_unlock_irqrestore(&sm->lock, flags); 123 spin_unlock_irqrestore(&sm->lock, flags);
124 break; 124 break;
125 } 125 }
126 schedule_delayed_work(&si->softmac_scan, IEEE80211SOFTMAC_PROBE_DELAY); 126 queue_delayed_work(sm->wq, &si->softmac_scan, IEEE80211SOFTMAC_PROBE_DELAY);
127 spin_unlock_irqrestore(&sm->lock, flags); 127 spin_unlock_irqrestore(&sm->lock, flags);
128 return; 128 return;
129 } else { 129 } else {
@@ -190,7 +190,7 @@ int ieee80211softmac_start_scan_implementation(struct net_device *dev)
190 sm->scaninfo->started = 1; 190 sm->scaninfo->started = 1;
191 sm->scaninfo->stop = 0; 191 sm->scaninfo->stop = 0;
192 INIT_COMPLETION(sm->scaninfo->finished); 192 INIT_COMPLETION(sm->scaninfo->finished);
193 schedule_delayed_work(&sm->scaninfo->softmac_scan, 0); 193 queue_delayed_work(sm->wq, &sm->scaninfo->softmac_scan, 0);
194 spin_unlock_irqrestore(&sm->lock, flags); 194 spin_unlock_irqrestore(&sm->lock, flags);
195 return 0; 195 return 0;
196} 196}