[Make-wifi-fast] [PATCH RFC/RFT 3/4] ath10k: Pass last TX bitrate up to mac80211

Toke Høiland-Jørgensen toke at redhat.com
Thu Sep 19 08:22:47 EDT 2019


From: Toke Høiland-Jørgensen <toke at redhat.com>

Use the newly added API to pass the last_tx_bitrate up to mac80211. The
multiplication is because ath10k keeps it internally as units of 100kbps,
whereas for mac80211 we just use kbps as the variable unit.

Signed-off-by: Toke Høiland-Jørgensen <toke at redhat.com>
---
 drivers/net/wireless/ath/ath10k/htt_rx.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/wireless/ath/ath10k/htt_rx.c b/drivers/net/wireless/ath/ath10k/htt_rx.c
index 83a7fb68fd24..0617341eb70c 100644
--- a/drivers/net/wireless/ath/ath10k/htt_rx.c
+++ b/drivers/net/wireless/ath/ath10k/htt_rx.c
@@ -3454,6 +3454,7 @@ ath10k_update_per_peer_tx_stats(struct ath10k *ar,
 	arsta->txrate.nss = txrate.nss;
 	arsta->txrate.bw = ath10k_bw_to_mac80211_bw(txrate.bw);
 	arsta->last_tx_bitrate = cfg80211_calculate_bitrate(&arsta->txrate);
+	ieee80211_sta_set_last_tx_bitrate(sta, arsta->last_tx_bitrate * 100);
 	if (sgi)
 		arsta->txrate.flags |= RATE_INFO_FLAGS_SHORT_GI;
 



More information about the Make-wifi-fast mailing list