summaryrefslogtreecommitdiffstats
path: root/net/mac80211
diff options
context:
space:
mode:
authorJohannes Berg <johannes@sipsolutions.net>2009-05-19 21:26:07 +0200
committerJohn W. Linville <linville@tuxdriver.com>2009-05-22 14:05:59 -0400
commit4ef699fb771d347b31ddafd214c0dd47b90f7f0f (patch)
tree6e27e3c02468d603488f632fce0faa7591d80fc9 /net/mac80211
parent87057825824973f29cf2f37cff1e549170b2d7e6 (diff)
downloadblackbird-op-linux-4ef699fb771d347b31ddafd214c0dd47b90f7f0f.tar.gz
blackbird-op-linux-4ef699fb771d347b31ddafd214c0dd47b90f7f0f.zip
mac80211: fix probe response wait timing
In "mac80211: split out and decrease probe wait time" I tried to reduce the time waiting for a probe response, but failed to take into account the case where we are detecting beacon loss in software -- in that case we still wait the monitoring time rather than the probe wait time. Fix this by refactoring the mod_timer() calls in ieee80211_associated(). Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211')
-rw-r--r--net/mac80211/mlme.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c
index b7f9c60793dd..ac6883f5a43e 100644
--- a/net/mac80211/mlme.c
+++ b/net/mac80211/mlme.c
@@ -1389,8 +1389,8 @@ static void ieee80211_associated(struct ieee80211_sub_if_data *sdata)
ifmgd->flags |= IEEE80211_STA_PROBEREQ_POLL;
ieee80211_send_probe_req(sdata, ifmgd->bssid, ifmgd->ssid,
ifmgd->ssid_len, NULL, 0);
+ mod_timer(&ifmgd->timer, jiffies + IEEE80211_PROBE_WAIT);
goto unlock;
-
}
if (time_after(jiffies, sta->last_rx + IEEE80211_PROBE_IDLE_TIME)) {
@@ -1399,15 +1399,16 @@ static void ieee80211_associated(struct ieee80211_sub_if_data *sdata)
ifmgd->ssid_len, NULL, 0);
}
+ if (!disassoc)
+ mod_timer(&ifmgd->timer,
+ jiffies + IEEE80211_MONITORING_INTERVAL);
+
unlock:
rcu_read_unlock();
if (disassoc)
ieee80211_set_disassoc(sdata, true, true,
WLAN_REASON_PREV_AUTH_NOT_VALID);
- else
- mod_timer(&ifmgd->timer, jiffies +
- IEEE80211_MONITORING_INTERVAL);
}
OpenPOWER on IntegriCloud