Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 10ffb6a7 authored by Felix Fietkau's avatar Felix Fietkau Committed by John W. Linville
Browse files

ath9k: optimize ath_drain_all_txq



If the software has processed all packets, checking the hardware queue
is unnecessary.

Signed-off-by: default avatarFelix Fietkau <nbd@openwrt.org>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent bf3dac5a
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -1786,6 +1786,9 @@ bool ath_drain_all_txq(struct ath_softc *sc)
		if (!ATH_TXQ_SETUP(sc, i))
			continue;

		if (!sc->tx.txq[i].axq_depth)
			continue;

		if (ath9k_hw_numtxpending(ah, sc->tx.txq[i].axq_qnum))
			npend |= BIT(i);
	}