diff options
author | Johannes Berg <johannes@sipsolutions.net> | 2009-05-17 05:40:42 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-05-20 14:46:25 -0400 |
commit | 5bb644a0fd25a5e083ecbfaa92a211db99aa6ef7 (patch) | |
tree | d2a6d5ff2323db0c475be15c63bb8fc55482a1e2 /net/mac80211/mesh.h | |
parent | cc32abd494c0a8f76f2638e3f3a76e01c68bc9ea (diff) |
mac80211: cancel/restart all timers across suspend/resume
We forgot to cancel all timers in mac80211 when suspending.
In particular we forgot to deal with some things that can
cause hardware reconfiguration -- while it is down.
While at it we go ahead and add a warning in ieee80211_sta_work()
if its run while the suspend->resume cycle is in effect. This
should not happen and if it does it would indicate there is
a bug lurking in either mac80211 or mac80211 drivers.
With this now wpa_supplicant doesn't blink when I go to suspend
and resume where as before there where issues with some timers
running during the suspend->resume cycle. This caused a lot of
incorrect assumptions and would at times bring back the device
in an incoherent, but mostly recoverable, state.
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/mesh.h')
-rw-r--r-- | net/mac80211/mesh.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/net/mac80211/mesh.h b/net/mac80211/mesh.h index d891d7ddccd7..832bb503ca9b 100644 --- a/net/mac80211/mesh.h +++ b/net/mac80211/mesh.h | |||
@@ -267,6 +267,8 @@ void mesh_path_timer(unsigned long data); | |||
267 | void mesh_path_flush_by_nexthop(struct sta_info *sta); | 267 | void mesh_path_flush_by_nexthop(struct sta_info *sta); |
268 | void mesh_path_discard_frame(struct sk_buff *skb, | 268 | void mesh_path_discard_frame(struct sk_buff *skb, |
269 | struct ieee80211_sub_if_data *sdata); | 269 | struct ieee80211_sub_if_data *sdata); |
270 | void mesh_path_quiesce(struct ieee80211_sub_if_data *sdata); | ||
271 | void mesh_path_restart(struct ieee80211_sub_if_data *sdata); | ||
270 | 272 | ||
271 | #ifdef CONFIG_MAC80211_MESH | 273 | #ifdef CONFIG_MAC80211_MESH |
272 | extern int mesh_allocated; | 274 | extern int mesh_allocated; |
@@ -294,10 +296,20 @@ static inline void mesh_path_activate(struct mesh_path *mpath) | |||
294 | 296 | ||
295 | void ieee80211_mesh_notify_scan_completed(struct ieee80211_local *local); | 297 | void ieee80211_mesh_notify_scan_completed(struct ieee80211_local *local); |
296 | 298 | ||
299 | void ieee80211_mesh_quiesce(struct ieee80211_sub_if_data *sdata); | ||
300 | void ieee80211_mesh_restart(struct ieee80211_sub_if_data *sdata); | ||
301 | void mesh_plink_quiesce(struct sta_info *sta); | ||
302 | void mesh_plink_restart(struct sta_info *sta); | ||
297 | #else | 303 | #else |
298 | #define mesh_allocated 0 | 304 | #define mesh_allocated 0 |
299 | static inline void | 305 | static inline void |
300 | ieee80211_mesh_notify_scan_completed(struct ieee80211_local *local) {} | 306 | ieee80211_mesh_notify_scan_completed(struct ieee80211_local *local) {} |
307 | static inline void ieee80211_mesh_quiesce(struct ieee80211_sub_if_data *sdata) | ||
308 | {} | ||
309 | static inline void ieee80211_mesh_restart(struct ieee80211_sub_if_data *sdata) | ||
310 | {} | ||
311 | static inline void mesh_plink_quiesce(struct sta_info *sta) {} | ||
312 | static inline void mesh_plink_restart(struct sta_info *sta) {} | ||
301 | #endif | 313 | #endif |
302 | 314 | ||
303 | #endif /* IEEE80211S_H */ | 315 | #endif /* IEEE80211S_H */ |