ath11k: Add support for ring backpressure stats
authorSriram R <srirrama@codeaurora.org>
Thu, 11 Jun 2020 05:09:54 +0000 (08:09 +0300)
committerKalle Valo <kvalo@codeaurora.org>
Mon, 15 Jun 2020 14:33:12 +0000 (17:33 +0300)
commit71fbc847978f51629856d0ef7d3645d9322fb340
tree00d69aab5f63db211c21c63a5d941630d4f011e8
parent0dd6392ac2c0eb3e229631744f54b61789139e33
ath11k: Add support for ring backpressure stats

Add support for collecting and dumping the ring backpressure
stats via debugfs. Stats are dumped only if events are
received for the specific ring.

Below command can be used to obtain these stats as part of soc dp stats.
cat /sys/kernel/debug/ath11k/ipq8074/soc_dp_stats

 Sample Output - When No stats available:

 Backpressure Stats
 ==================
 No Ring Backpressure stats received

 Sample Output -  When ring bp stats available for specific ring

 Backpressure Stats
 ==================
 Ring: REO2SW1_RING
 count: 1
 hp: 2
 tp: 2
 seen before: 4ms

Tested-on: IPQ8074 hw2.0 AHB WLAN.HK.2.1.0.1-01213-QCAHKSWPL_SILICONZ-1

Signed-off-by: Sriram R <srirrama@codeaurora.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/1591768308-32005-3-git-send-email-srirrama@codeaurora.org
drivers/net/wireless/ath/ath11k/core.h
drivers/net/wireless/ath/ath11k/debug.c
drivers/net/wireless/ath/ath11k/dp.h
drivers/net/wireless/ath/ath11k/dp_rx.c