diff options
author | Chris Wright <chrisw@sous-sol.org> | 2013-07-31 12:12:24 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-08-20 08:43:03 -0700 |
commit | 42c8df37807471eac800b06891329e70b789cb44 (patch) | |
tree | e71041b678eb3a36932c118fbf29d1a4032c4187 /net/mac80211/mlme.c | |
parent | 7febdf14e427e1ed642f0a0c97182d50b6ce199e (diff) | |
download | linux-3.10-42c8df37807471eac800b06891329e70b789cb44.tar.gz linux-3.10-42c8df37807471eac800b06891329e70b789cb44.tar.bz2 linux-3.10-42c8df37807471eac800b06891329e70b789cb44.zip |
mac80211: fix infinite loop in ieee80211_determine_chantype
commit b56e4b857c5210e848bfb80e074e5756a36cd523 upstream.
Commit "3d9646d mac80211: fix channel selection bug" introduced a possible
infinite loop by moving the out target above the chandef_downgrade
while loop. When we downgrade to NL80211_CHAN_WIDTH_20_NOHT, we jump
back up to re-run the while loop...indefinitely. Replace goto with
break and carry on. This may not be sufficient to connect to the AP,
but will at least keep the cpu from livelocking. Thanks to Derek Atkins
as an extra pair of debugging eyes.
Signed-off-by: Chris Wright <chrisw@sous-sol.org>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net/mac80211/mlme.c')
-rw-r--r-- | net/mac80211/mlme.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c index 87499f8da56..1f57de7b7c0 100644 --- a/net/mac80211/mlme.c +++ b/net/mac80211/mlme.c @@ -366,7 +366,7 @@ out: if (WARN_ON(chandef->width == NL80211_CHAN_WIDTH_20_NOHT)) { ret = IEEE80211_STA_DISABLE_HT | IEEE80211_STA_DISABLE_VHT; - goto out; + break; } ret |= chandef_downgrade(chandef); |