diff options
author | Johannes Berg <johannes.berg@intel.com> | 2012-06-20 22:11:33 +0400 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2012-06-20 22:12:12 +0400 |
commit | 0f6b3f597daab2254614e2773e322e73fb1b6f4b (patch) | |
tree | 88a4d19016a1564598e9e083444d1948dae5c99d /net/mac80211/cfg.c | |
parent | 3bfda62c50b0a4b118dcfce36686508ca2892292 (diff) | |
download | linux-0f6b3f597daab2254614e2773e322e73fb1b6f4b.tar.xz |
mac80211: fix double-start of remain-on-channel
When a remain-on-channel item is deleted, we remove it
from the list and then start the next item. However,
if it wasn't actually the first item then calling
ieee80211_start_next_roc() is wrong as it will start
the first item -- even if that was already started.
Fix the two places that do this and add a warning to
prevent the problem from reoccurring.
Reported-by: Eliad Peller <eliad@wizery.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211/cfg.c')
-rw-r--r-- | net/mac80211/cfg.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c index a6abcd473434..03aff23c70fd 100644 --- a/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c @@ -2362,7 +2362,8 @@ static int ieee80211_cancel_roc(struct ieee80211_local *local, list_del(&found->list); - ieee80211_start_next_roc(local); + if (found->started) + ieee80211_start_next_roc(local); mutex_unlock(&local->mtx); ieee80211_roc_notify_destroy(found); |