Commit 48531847 authored by Johannes Berg's avatar Johannes Berg Committed by John W. Linville
Browse files

mac80211: fix mlme timeouts

When a new MLME work is created, its timeout is initialised
to 0. This is wrong, it could then be thought of as having
an actual timeout in the future (time_is_after_jiffies() can
return true). Instead, it should be initialised to jiffies
so that it will run right away as soon as the mlme work is
Signed-off-by: default avatarJohannes Berg <>
Reported-by: default avatarLuciano Roth Coelho <>
Reported-by: default avatarAlban Browaeys <>
Signed-off-by: default avatarJohn W. Linville <>
parent 09f97e0f
......@@ -2377,6 +2377,7 @@ int ieee80211_mgd_auth(struct ieee80211_sub_if_data *sdata,
wk->state = IEEE80211_MGD_STATE_PROBE;
wk->auth_alg = auth_alg;
wk->timeout = jiffies; /* run right away */
* XXX: if still associated need to tell AP that we're going
......@@ -2448,6 +2449,7 @@ int ieee80211_mgd_assoc(struct ieee80211_sub_if_data *sdata,
wk->state = IEEE80211_MGD_STATE_ASSOC;
wk->tries = 0;
wk->timeout = jiffies; /* run right away */
if (req->use_mfp) {
ifmgd->mfp = IEEE80211_MFP_REQUIRED;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment