mac80211: Do not call release_buffered_frames if not available.
RFC 7/7 mac80211: Do not call release_buffered_frames if not available.
From: Dmitry Tarnyagin <[email protected]>
Date: Wed, 5 Oct 2011 13:20:04 +0200
A new .release_buffered_frames callback was introduced recently. Check for the callback presence was missing in the mac80211 code, and PM state could get broken in some cases.
--- net/mac80211/sta_info.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-)
net/mac80211/sta_info.c +3 -1
@@ -1262,7 +1262,9 @@ ieee80211_sta_ps_deliver_response(struct sta_info *sta, tids =ieee80211_tids_for_ac (ac);if (!found) { - driver_release_tids = sta->driver_buffered_tids & tids; +if (local->ops->release_buffered_frames) + driver_release_tids = + sta->driver_buffered_tids & tids;if (driver_release_tids) { found = true; }else {
Signature · 1 line
1.7.1
Johannes Berg
maintainerQuoted 6 lines · Dmitry Tarnyagin
From: Dmitry Tarnyagin <[email protected]>
Date: Wed, 5 Oct 2011 13:20:04 +0200A new .release_buffered_frames callback was introduced recently. Check for the callback presence was missing in the mac80211 code, and PM state could get broken in some cases.
Interesting, but we do check:
drv_release_buffered_frames(struct ieee80211_local *local,
struct sta_info *sta, u16 tids, int num_frames, enum ieee80211_frame_release_type reason, bool more_data)
{
trace_drv_release_buffered_frames(local, &sta->sta, tids, num_frames,
reason, more_data);
if (local->ops->release_buffered_frames)
local->ops->release_buffered_frames(&local->hw, &sta->sta, tids,So whatever you're trying to do must be something else.
johannes