* [PATCH wireless] wifi: mac80211: wake TXQs of all ACs with fewer HW queues than ACs
@ 2026-11-25 2:32 Jason Self
2026-11-25 6:57 ` Johannes Berg
0 siblings, 1 reply; 2+ messages in thread
From: Jason Self @ 2026-11-25 2:32 UTC (permalink / raw)
To: johannes; +Cc: Jason Self, linux-wireless
_ieee80211_wake_txqs() walks only one AC when the hardware has fewer
queues than ACs, but __ieee80211_wake_txqs() selects TXQs by AC, so only
AC_VO TXQs are woken. A dirty AC_BE TXQ then waits for a later frame.
With vt6656 and dynamic power save, this delayed pings by up to a minute.
Walk all ACs; with fewer queues than ACs they all map to queue 0.
Found and written with Claude Code, an AI coding assistant; tested on
hardware by the submitter.
Fixes: 21a5d4c3a45c ("mac80211: add stop/start logic for software TXQs")
Signed-off-by: Jason Self <j@jxself.org>
---
net/mac80211/util.c | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/net/mac80211/util.c b/net/mac80211/util.c
index 44feb80274..442606a4ae 100644
--- a/net/mac80211/util.c
+++ b/net/mac80211/util.c
@@ -403,14 +403,10 @@ __acquires(&local->queue_stop_reason_lock)
_ieee80211_wake_txqs(struct ieee80211_local *local, unsigned long *flags)
{
struct ieee80211_sub_if_data *sdata;
- int n_acs = IEEE80211_NUM_ACS;
int i;
rcu_read_lock();
- if (local->hw.queues < IEEE80211_NUM_ACS)
- n_acs = 1;
-
for (i = 0; i < local->hw.queues; i++) {
if (local->queue_stop_reasons[i])
continue;
@@ -419,7 +415,12 @@ _ieee80211_wake_txqs(struct ieee80211_local *local, unsigned long *flags)
list_for_each_entry_rcu(sdata, &local->interfaces, list) {
int ac;
- for (ac = 0; ac < n_acs; ac++) {
+ /*
+ * Walk all ACs even with fewer hardware queues than
+ * ACs: they then all map to queue 0, and
+ * __ieee80211_wake_txqs() selects TXQs by AC.
+ */
+ for (ac = 0; ac < IEEE80211_NUM_ACS; ac++) {
int ac_queue = sdata->vif.hw_queue[ac];
if (ac_queue == i ||
--
2.43.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH wireless] wifi: mac80211: wake TXQs of all ACs with fewer HW queues than ACs
2026-11-25 2:32 [PATCH wireless] wifi: mac80211: wake TXQs of all ACs with fewer HW queues than ACs Jason Self
@ 2026-11-25 6:57 ` Johannes Berg
0 siblings, 0 replies; 2+ messages in thread
From: Johannes Berg @ 2026-11-25 6:57 UTC (permalink / raw)
To: Jason Self; +Cc: linux-wireless
On Tue, 2026-11-24 at 18:32 -0800, Jason Self wrote:
> _ieee80211_wake_txqs() walks only one AC when the hardware has fewer
> queues than ACs, but __ieee80211_wake_txqs() selects TXQs by AC, so only
> AC_VO TXQs are woken. A dirty AC_BE TXQ then waits for a later frame.
> With vt6656
There's no such driver. Either way, don't let LLMs write everything, the
comment is meaningless as usual.
johannes
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-11-25 6:57 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-25 2:32 [PATCH wireless] wifi: mac80211: wake TXQs of all ACs with fewer HW queues than ACs Jason Self
2026-11-25 6:57 ` Johannes Berg
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox