Commit 29363fb6 authored by Kuan-Chung Chen's avatar Kuan-Chung Chen Committed by Kalle Valo
Browse files

wifi: rtw89: fix potential TX stuck



The potential TX stuck occurs when there are lots of packets to be
transmitted and the boundary of the tx_resource is hit. Add this
patch to avoid the TX stuck when burst traffic.

Signed-off-by: default avatarKuan-Chung Chen <damon.chen@realtek.com>
Signed-off-by: default avatarPing-Ke Shih <pkshih@realtek.com>
Signed-off-by: default avatarKalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20220610072610.27095-6-pkshih@realtek.com
parent 6a5a783a
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -1991,6 +1991,10 @@ static void rtw89_core_txq_schedule(struct rtw89_dev *rtwdev, u8 ac, bool *reinv
		ieee80211_return_txq(hw, txq, sched_txq);
		if (frame_cnt != 0)
			rtw89_core_tx_kick_off(rtwdev, rtw89_core_get_qsel(rtwdev, txq->tid));

		/* bound of tx_resource could get stuck due to burst traffic */
		if (frame_cnt == tx_resource)
			*reinvoke = true;
	}
	ieee80211_txq_schedule_end(hw, ac);
}