summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRajkumar Manoharan <rmanohar@qca.qualcomm.com>2011-07-07 23:33:39 +0530
committerJonas ABERG <jonas.aberg@stericsson.com>2011-10-28 11:08:11 +0200
commitfbdf925b68acd45152a831931bbe2f3cf5d8ff50 (patch)
tree54445632f2b1a684aeb0301385cf55c024f9ac01
parent60f79756606dcbf1da11a777e9f83b4d14ea790f (diff)
mac80211: Restart STA timers only on associated state
commit 676b58c27475a9defccc025fea1cbd2b141ee539 upstream. A panic was observed when the device is failed to resume properly, and there are no running interfaces. ieee80211_reconfig tries to restart STA timers on unassociated state. Signed-off-by: Rajkumar Manoharan <rmanohar@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> Change-Id: Ieab38e91ba93b6829bc0d1537e4121f953c646b2 Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/35613 Tested-by: Per VAHLNE <per.xx.vahlne@stericsson.com> Reviewed-by: Jonas ABERG <jonas.aberg@stericsson.com>
-rw-r--r--net/mac80211/mlme.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c
index d595265d6c2..7a334fdd8d6 100644
--- a/net/mac80211/mlme.c
+++ b/net/mac80211/mlme.c
@@ -2200,6 +2200,9 @@ void ieee80211_sta_restart(struct ieee80211_sub_if_data *sdata)
{
struct ieee80211_if_managed *ifmgd = &sdata->u.mgd;
+ if (!ifmgd->associated)
+ return;
+
if (test_and_clear_bit(TMR_RUNNING_TIMER, &ifmgd->timers_running))
add_timer(&ifmgd->timer);
if (test_and_clear_bit(TMR_RUNNING_CHANSW, &ifmgd->timers_running))