public inbox for ath12k@lists.infradead.org
 help / color / mirror / Atom feed
* [PATCH ath-current 0/7] wifi: ath12k: Fix Issues in REO RX Queue Updates
@ 2025-08-06 11:17 Nithyanantham Paramasivam
  2025-08-06 11:17 ` [PATCH ath-current 1/7] wifi: ath12k: Increase DP_REO_CMD_RING_SIZE to 256 Nithyanantham Paramasivam
                   ` (10 more replies)
  0 siblings, 11 replies; 15+ messages in thread
From: Nithyanantham Paramasivam @ 2025-08-06 11:17 UTC (permalink / raw)
  To: ath12k; +Cc: linux-wireless, Nithyanantham Paramasivam

During stress test scenarios, when the REO command ring becomes full,
the RX queue update command issued during peer deletion fails due to
insufficient space. In response, the host performs a dma_unmap and
frees the associated memory. However, the hardware still retains a
reference to the same memory address. If the kernel later reallocates
this address, unaware that the hardware is still using it, it can
lead to memory corruption-since the host might access or modify
memory that is still actively referenced by the hardware.

Implement a retry mechanism for the HAL_REO_CMD_UPDATE_RX_QUEUE
command during TID deletion to prevent memory corruption. Introduce
a new list, reo_cmd_update_rx_queue_list, in the dp structure to
track pending RX queue updates. Protect this list with
reo_rxq_flush_lock, which also ensures synchronized access to
reo_cmd_cache_flush_list. Defer memory release until hardware
confirms the virtual address is no longer in use, avoiding immediate
deallocation on command failure. Release memory for pending RX queue
updates via ath12k_dp_rx_reo_cmd_list_cleanup() on system reset
if hardware confirmation is not received.

Additionally, increase DP_REO_CMD_RING_SIZE to 256 to reduce the
likelihood of ring exhaustion. Use a 1KB cache flush command for
QoS TID descriptors to improve efficiency.

Manish Dharanenthiran (2):
  wifi: ath12k: Add Retry Mechanism for REO RX Queue Update Failures
  wifi: ath12k: Use 1KB Cache Flush Command for QoS TID Descriptors

Nithyanantham Paramasivam (5):
  wifi: ath12k: Increase DP_REO_CMD_RING_SIZE to 256
  wifi: ath12k: Refactor RX TID deletion handling into helper function
  wifi: ath12k: Refactor RX TID buffer cleanup into helper function
  wifi: ath12k: Refactor REO command to use ath12k_dp_rx_tid_rxq
  wifi: ath12k: Fix flush cache failure during RX queue update

 drivers/net/wireless/ath/ath12k/dp.c       |   2 +
 drivers/net/wireless/ath/ath12k/dp.h       |  12 +-
 drivers/net/wireless/ath/ath12k/dp_rx.c    | 336 ++++++++++++++-------
 drivers/net/wireless/ath/ath12k/dp_rx.h    |  18 +-
 drivers/net/wireless/ath/ath12k/hal.h      |   1 +
 drivers/net/wireless/ath/ath12k/hal_desc.h |   1 +
 drivers/net/wireless/ath/ath12k/hal_rx.c   |   3 +
 7 files changed, 251 insertions(+), 122 deletions(-)


base-commit: 95bf875b89b48a95a82aca922eeaf19d52543028
-- 
2.17.1



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

end of thread, other threads:[~2025-09-22 20:43 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-06 11:17 [PATCH ath-current 0/7] wifi: ath12k: Fix Issues in REO RX Queue Updates Nithyanantham Paramasivam
2025-08-06 11:17 ` [PATCH ath-current 1/7] wifi: ath12k: Increase DP_REO_CMD_RING_SIZE to 256 Nithyanantham Paramasivam
2025-08-06 11:17 ` [PATCH ath-current 2/7] wifi: ath12k: Refactor RX TID deletion handling into helper function Nithyanantham Paramasivam
2025-08-06 11:17 ` [PATCH ath-current 3/7] wifi: ath12k: Refactor RX TID buffer cleanup " Nithyanantham Paramasivam
2025-08-06 11:17 ` [PATCH ath-current 4/7] wifi: ath12k: Refactor REO command to use ath12k_dp_rx_tid_rxq Nithyanantham Paramasivam
2025-08-06 11:17 ` [PATCH ath-current 5/7] wifi: ath12k: Add Retry Mechanism for REO RX Queue Update Failures Nithyanantham Paramasivam
2025-08-06 11:17 ` [PATCH ath-current 6/7] wifi: ath12k: Fix flush cache failure during RX queue update Nithyanantham Paramasivam
2025-08-06 11:17 ` [PATCH ath-current 7/7] wifi: ath12k: Use 1KB Cache Flush Command for QoS TID Descriptors Nithyanantham Paramasivam
2025-08-06 20:02 ` [PATCH ath-current 0/7] wifi: ath12k: Fix Issues in REO RX Queue Updates Nicolas Escande
2025-08-07 12:31   ` Nithyanantham Paramasivam
2025-08-07 13:39     ` Nicolas Escande
2025-09-11  5:58       ` Nithyanantham Paramasivam
2025-09-20 19:46 ` Vasanthakumar Thiagarajan
2025-09-22  5:14 ` Baochen Qiang
2025-09-22 20:43 ` Jeff Johnson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox