[PATCH] mac80211: only schedule TXQ when reasonable airtime reporting
Toke Høiland-Jørgensen
toke at toke.dk
Fri Feb 5 08:29:19 EST 2021
Ryder Lee <ryder.lee at mediatek.com> writes:
> For some drivers and hardware may report faulty airtime, which ends up
> with excessive hold time (~0.9s on mt7915 multiclent tests) impacting
> system performance.
>
> Although issue has been fixed in driver, but it make sense to select txqi
> depends on a reasonable airtime reporting to prevent such a case from
> happening again.
I think I see what you're trying to do with the patch, but this commit
message makes no sense. What, exactly, was the error you were seeing
that this is supposed to fix?
> Tested-by: Jiao Bo <jiao.bao at mediatek.com>
> Tested-by: Sujuan Chen <sujuan.chen at mediatek.com>
> Signed-off-by: Ryder Lee <ryder.lee at mediatek.com>
> ---
> net/mac80211/tx.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c
> index 6422da6690f7..0b8a8c3600f4 100644
> --- a/net/mac80211/tx.c
> +++ b/net/mac80211/tx.c
> @@ -3770,6 +3770,10 @@ struct ieee80211_txq *ieee80211_next_txq(struct ieee80211_hw *hw, u8 ac)
> sta->airtime_weight;
>
> if (deficit < 0 || !aql_check) {
> + if (txqi->schedule_round == local->schedule_round[ac])
> + goto out;
> +
> + txqi->schedule_round = local->schedule_round[ac];
I think this change may be worth making anyway, but for a different
reason: Without it, a station that fails aql_check will keep getting
recycled through the list, advancing its deficit. Which could actually
be the reason AQL breaks airtime fairness; did you observe any
difference in fairness with this change?
-Toke
More information about the Linux-mediatek
mailing list