ath10k: Fix tx hanging
PATCH 1/1 ath10k: Fix tx hanging
While running stress tests in roaming scenarios (switching ap's every 5 seconds, we discovered a issue which leads to tx hangings of exactly 5 seconds while or after scanning for new accesspoints. We found out that this hanging is triggered by ath10k_mac_wait_tx_complete since the empty_tx_wq was not wake when the num_tx_pending counter reaches zero. To fix this, we simply move the wake_up call to htt_tx_dec_pending, since this call was missed on several locations within the ath10k code.
--- drivers/net/wireless/ath/ath10k/htt_tx.c | 3 +++ drivers/net/wireless/ath/ath10k/txrx.c | 2 -- 2 files changed, 3 insertions(+), 2 deletions(-)
drivers/net/wireless/ath/ath10k/htt_tx.c +3 -0
@@ -147,6 +147,9 @@ void ath10k_htt_tx_dec_pending(struct ath10k_htt *htt) htt->num_pending_tx--;if (htt->num_pending_tx == htt->max_num_pending_tx -1 )ath10k_mac_tx_unlock (htt->ar,ATH10K_TX_PAUSE_Q_FULL ); + +if (htt->num_pending_tx ==0 ) +wake_up (&htt->empty_tx_wq); }int ath10k_htt_tx_inc_pending (struct ath10k_htt *htt)
drivers/net/wireless/ath/ath10k/txrx.c +0 -2
@@ -82,8 +82,6 @@ int ath10k_txrx_tx_unref(struct ath10k_htt *htt, flags = skb_cb->flags;ath10k_htt_tx_free_msdu_id (htt, tx_done->msdu_id);ath10k_htt_tx_dec_pending (htt); -if (htt->num_pending_tx ==0 ) -wake_up (&htt->empty_tx_wq);spin_unlock_bh (&htt->tx_lock);rcu_read_lock ();
Signature · 7 lines
2.31.1 _______________________________________________ ath10k mailing list [email protected] http://lists.infradead.org/mailman/listinfo/ath10k
Quoted 10 lines · Sebastian Gottschall
While running stress tests in roaming scenarios (switching ap's every 5 seconds, we discovered a issue which leads to tx hangings of exactly 5 seconds while or after scanning for new accesspoints. We found out that this hanging is triggered by
ath10k_mac_wait_tx_completesince theempty_tx_wqwas not wake when thenum_tx_pendingcounter reaches zero. To fix this, we simply move thewake_upcall tohtt_tx_dec_pending, since this call was missed on several locations within the ath10k code.Signed-off-by Sebastian Gottschall <[email protected]>Signed-off-by Kalle Valo <[email protected]>
Patch applied to ath-next branch of ath.git, thanks.
e8a91863eba3 ath10k: Fix tx hanging
Signature · 3 lines
https://patchwork.kernel.org/project/linux-wireless/patch/[email protected]/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches