* [PATCH 1/2] mac80211: set CLEAR_PS for pspolled frames
@ 2009-04-18 16:30 Christian Lamparter
2009-04-18 17:39 ` [PATCH 1/2 v2] " Christian Lamparter
0 siblings, 1 reply; 2+ messages in thread
From: Christian Lamparter @ 2009-04-18 16:30 UTC (permalink / raw)
To: linux-wireless; +Cc: John W. Linville, Johannes Berg
This patch sets IEEE80211_TX_CTL_CLEAR_PS_FILT for outgoing
frames for a half-wake station.
this is necessary if one wants to get ps-poll working properly with a p54 ap.
Signed-off-by: Christian Lamparter <chunkeey@web.de>
---
diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c
index 3fb04a8..4c2e19e 100644
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -409,8 +409,19 @@ ieee80211_tx_h_unicast_ps_buf(struct ieee80211_tx_data *tx)
sta->sta.addr);
}
#endif /* CONFIG_MAC80211_VERBOSE_PS_DEBUG */
- clear_sta_flags(sta, WLAN_STA_PSPOLL);
+ if (test_and_clear_sta_flags(sta, WLAN_STA_PSPOLL)) {
+ /*
+ * The sleeping station with pending data is now snoozing.
+ * It queried us for its buffered frames and will go back
+ * to deep sleep once it got everything.
+ *
+ * inform the driver, in case the hardware does powersave
+ * frame filtering and keeps a station blacklist on its own
+ * (e.g: p54), so that frames can be delivered unimpeded.
+ */
+ info->flags |= IEEE80211_TX_CTL_CLEAR_PS_FILT;
+ }
return TX_CONTINUE;
}
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [PATCH 1/2 v2] mac80211: set CLEAR_PS for pspolled frames
2009-04-18 16:30 [PATCH 1/2] mac80211: set CLEAR_PS for pspolled frames Christian Lamparter
@ 2009-04-18 17:39 ` Christian Lamparter
0 siblings, 0 replies; 2+ messages in thread
From: Christian Lamparter @ 2009-04-18 17:39 UTC (permalink / raw)
To: linux-wireless; +Cc: John W. Linville, Johannes Berg
This patch sets IEEE80211_TX_CTL_CLEAR_PS_FILT for outgoing
frames for a half-wake station.
this is necessary if one wants to get ps-poll working properly with a p54 ap.
Signed-off-by: Christian Lamparter <chunkeey@web.de>
---
changes:
added a explanation, why we can safely remove the filter now.
---
diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c
index 3fb04a8..f336cc7 100644
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -409,8 +409,24 @@ ieee80211_tx_h_unicast_ps_buf(struct ieee80211_tx_data *tx)
sta->sta.addr);
}
#endif /* CONFIG_MAC80211_VERBOSE_PS_DEBUG */
- clear_sta_flags(sta, WLAN_STA_PSPOLL);
+ if (test_and_clear_sta_flags(sta, WLAN_STA_PSPOLL)) {
+ /*
+ * The sleeping station with pending data is now snoozing.
+ * It queried us for its buffered frames and will go back
+ * to deep sleep once it got everything.
+ *
+ * inform the driver, in case the hardware does powersave
+ * frame filtering and keeps a station blacklist on its own
+ * (e.g: p54), so that frames can be delivered unimpeded.
+ *
+ * Note: It should be save to disable the filter now.
+ * As, it is really unlikely that we still have any pending
+ * frame for this station in the hw's buffers/fifos left,
+ * that is not rejected with a unsuccessful tx_status yet.
+ */
+ info->flags |= IEEE80211_TX_CTL_CLEAR_PS_FILT;
+ }
return TX_CONTINUE;
}
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-04-18 17:39 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-04-18 16:30 [PATCH 1/2] mac80211: set CLEAR_PS for pspolled frames Christian Lamparter
2009-04-18 17:39 ` [PATCH 1/2 v2] " Christian Lamparter
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.