linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] ath10k: fix different tx duration output
@ 2019-04-17  8:17 Lei Wang
  2019-04-17  9:26 ` Toke Høiland-Jørgensen
  2019-05-07 14:05 ` Kalle Valo
  0 siblings, 2 replies; 7+ messages in thread
From: Lei Wang @ 2019-04-17  8:17 UTC (permalink / raw)
  To: ath10k; +Cc: linux-wireless, Lei Wang

TX duration output of tx_stats in debugfs and station dump had big
difference because they got tx duration value from different statistic
data. We should use the same statistic data.

Tested: QCA988X with firmware ver 10.2.4-1.0-00043

Signed-off-by: Lei Wang <leiwa@codeaurora.org>
---
 drivers/net/wireless/ath/ath10k/mac.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/net/wireless/ath/ath10k/mac.c b/drivers/net/wireless/ath/ath10k/mac.c
index b73c23d..5414169 100644
--- a/drivers/net/wireless/ath/ath10k/mac.c
+++ b/drivers/net/wireless/ath/ath10k/mac.c
@@ -7977,6 +7977,11 @@ static void ath10k_sta_statistics(struct ieee80211_hw *hw,
 	sinfo->rx_duration = arsta->rx_duration;
 	sinfo->filled |= BIT_ULL(NL80211_STA_INFO_RX_DURATION);
 
+	if (arsta->tx_stats && ath10k_debug_is_extd_tx_stats_enabled(ar)) {
+		sinfo->tx_duration = arsta->tx_stats->tx_duration;
+		sinfo->filled |= 1ULL << NL80211_STA_INFO_TX_DURATION;
+	}
+
 	if (!arsta->txrate.legacy && !arsta->txrate.nss)
 		return;
 
-- 
1.9.1


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

end of thread, other threads:[~2019-05-07 14:05 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-04-17  8:17 [PATCH v2] ath10k: fix different tx duration output Lei Wang
2019-04-17  9:26 ` Toke Høiland-Jørgensen
2019-04-18  7:26   ` leiwa
2019-04-18  8:07     ` Toke Høiland-Jørgensen
2019-05-07 11:14       ` leiwa
2019-05-07 11:43         ` Toke Høiland-Jørgensen
2019-05-07 14:05 ` Kalle Valo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).