mac80211: flush workqueue a second time in suspend()
authorBob Copeland <me@bobcopeland.com>
Sat, 24 Jan 2009 18:21:14 +0000 (13:21 -0500)
committerJohn W. Linville <linville@tuxdriver.com>
Thu, 29 Jan 2009 21:01:42 +0000 (16:01 -0500)
Drivers can theoretically queue more work in one of their callbacks
from mac80211 suspend, so let's flush it once more to be on the safe
side, just before calling ->stop().

Signed-off-by: Bob Copeland <me@bobcopeland.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
net/mac80211/pm.c

index 6d17ed7..44525f5 100644 (file)
@@ -44,6 +44,9 @@ int __ieee80211_suspend(struct ieee80211_hw *hw)
                }
        }
 
+       /* flush again, in case driver queued work */
+       flush_workqueue(local->hw.workqueue);
+
        /* stop hardware */
        if (local->open_count) {
                ieee80211_led_radio(local, false);