Linux-Wireless Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH] mac80211: remove STA txq pending airtime underflow warning
@ 2020-07-25  8:45 Felix Fietkau
  2020-08-11  9:31 ` Toke Høiland-Jørgensen
  0 siblings, 1 reply; 2+ messages in thread
From: Felix Fietkau @ 2020-07-25  8:45 UTC (permalink / raw)
  To: linux-wireless; +Cc: johannes

This warning can trigger if there is a mismatch between frames that were
sent with the sta pointer set vs tx status frames reported for the sta address.

This can happen due to race conditions on re-creating stations, or even
in the case of .sta_add/remove being used instead of .sta_state, which can cause
frames to be sent to a station that has not been uploaded yet.

If there is an actual underflow issue, it should show up in the device airtime
warning below, so it is better to remove this one.

Signed-off-by: Felix Fietkau <nbd@nbd.name>
---
 net/mac80211/sta_info.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/net/mac80211/sta_info.c b/net/mac80211/sta_info.c
index cd8487bc6fc2..af4cc5fb678e 100644
--- a/net/mac80211/sta_info.c
+++ b/net/mac80211/sta_info.c
@@ -1923,9 +1923,7 @@ void ieee80211_sta_update_pending_airtime(struct ieee80211_local *local,
 	if (sta) {
 		tx_pending = atomic_sub_return(tx_airtime,
 					       &sta->airtime[ac].aql_tx_pending);
-		if (WARN_ONCE(tx_pending < 0,
-			      "STA %pM AC %d txq pending airtime underflow: %u, %u",
-			      sta->addr, ac, tx_pending, tx_airtime))
+		if (tx_pending < 0)
 			atomic_cmpxchg(&sta->airtime[ac].aql_tx_pending,
 				       tx_pending, 0);
 	}
-- 
2.24.0


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] mac80211: remove STA txq pending airtime underflow warning
  2020-07-25  8:45 [PATCH] mac80211: remove STA txq pending airtime underflow warning Felix Fietkau
@ 2020-08-11  9:31 ` Toke Høiland-Jørgensen
  0 siblings, 0 replies; 2+ messages in thread
From: Toke Høiland-Jørgensen @ 2020-08-11  9:31 UTC (permalink / raw)
  To: Felix Fietkau, linux-wireless; +Cc: johannes

Felix Fietkau <nbd@nbd.name> writes:

> This warning can trigger if there is a mismatch between frames that were
> sent with the sta pointer set vs tx status frames reported for the sta address.
>
> This can happen due to race conditions on re-creating stations, or even
> in the case of .sta_add/remove being used instead of .sta_state, which can cause
> frames to be sent to a station that has not been uploaded yet.
>
> If there is an actual underflow issue, it should show up in the device airtime
> warning below, so it is better to remove this one.

Fair enough.

Acked-by: Toke Høiland-Jørgensen <toke@redhat.com>


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, back to index

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-25  8:45 [PATCH] mac80211: remove STA txq pending airtime underflow warning Felix Fietkau
2020-08-11  9:31 ` Toke Høiland-Jørgensen

Linux-Wireless Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-wireless/0 linux-wireless/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-wireless linux-wireless/ https://lore.kernel.org/linux-wireless \
		linux-wireless@vger.kernel.org
	public-inbox-index linux-wireless

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-wireless


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git