]> www.infradead.org Git - users/jedix/linux-maple.git/commit
wifi: ath12k: avoid burning CPU while waiting for firmware stats
authorBaochen Qiang <quic_bqiang@quicinc.com>
Thu, 12 Jun 2025 01:31:50 +0000 (09:31 +0800)
committerJeff Johnson <jeff.johnson@oss.qualcomm.com>
Tue, 17 Jun 2025 23:28:35 +0000 (16:28 -0700)
commit9a353a4a11a475578be3c02dd17e70afe3a4a7f6
tree78bb22378c4454b7a9d22320d0048df57147f152
parenta48a931a32f88157db2baa31c10738a7fe660e93
wifi: ath12k: avoid burning CPU while waiting for firmware stats

ath12k_mac_get_fw_stats() is busy polling fw_stats_done flag while waiting
firmware finishing sending all events. This is not good as CPU is
monopolized and kept burning during the wait.

Change to the completion mechanism to fix it.

Tested-on: WCN7850 hw2.0 PCI WLAN.HMT.1.1.c5-00284.1-QCAHMTSWPL_V1.0_V2.0_SILICONZ-3
Tested-on: QCN9274 hw2.0 WLAN.WBE.1.5-01651-QCAHKSWPL_SILICONZ-1

Fixes: e367c924768b ("wifi: ath12k: Request vdev stats from firmware")
Reported-by: Grégoire Stein <gregoire.s93@live.fr>
Closes: https://lore.kernel.org/ath12k/AS8P190MB120575BBB25FCE697CD7D4988763A@AS8P190MB1205.EURP190.PROD.OUTLOOK.COM/
Signed-off-by: Baochen Qiang <quic_bqiang@quicinc.com>
Tested-by: Grégoire Stein <gregoire.s93@live.fr>
Link: https://patch.msgid.link/20250612-ath12k-fw-fixes-v1-2-12f594f3b857@quicinc.com
Signed-off-by: Jeff Johnson <jeff.johnson@oss.qualcomm.com>
drivers/net/wireless/ath/ath12k/core.c
drivers/net/wireless/ath/ath12k/core.h
drivers/net/wireless/ath/ath12k/mac.c
drivers/net/wireless/ath/ath12k/wmi.c