mirror of
https://github.com/torvalds/linux.git
synced 2026-05-29 17:43:52 +02:00
wifi: mac80211: fix missing RX bitrate update for mesh forwarding path
Currently, RX bitrate statistics are not updated for packets received on the mesh forwarding path during fast RX processing. This results in incomplete RX rate tracking in station dump outputs for mesh scenarios. Update ieee80211_invoke_fast_rx() to record the RX rate using sta_stats_encode_rate() and store it in the last_rate field of ieee80211_sta_rx_stats when RX_QUEUED is returned from ieee80211_rx_mesh_data(). This ensures that RX bitrate is properly accounted for in both RSS and non-RSS paths. Signed-off-by: Sarika Sharma <sarika.sharma@oss.qualcomm.com> Link: https://patch.msgid.link/20251024043627.1640447-1-sarika.sharma@oss.qualcomm.com Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:
parent
bca76b875d
commit
cc18fffa3a
|
|
@ -4952,6 +4952,11 @@ static bool ieee80211_invoke_fast_rx(struct ieee80211_rx_data *rx,
|
|||
|
||||
/* after this point, don't punt to the slowpath! */
|
||||
|
||||
if (fast_rx->uses_rss)
|
||||
stats = this_cpu_ptr(rx->link_sta->pcpu_rx_stats);
|
||||
else
|
||||
stats = &rx->link_sta->rx_stats;
|
||||
|
||||
if (rx->key && !(status->flag & RX_FLAG_MIC_STRIPPED) &&
|
||||
pskb_trim(skb, skb->len - fast_rx->icv_len))
|
||||
goto drop;
|
||||
|
|
@ -4986,6 +4991,8 @@ static bool ieee80211_invoke_fast_rx(struct ieee80211_rx_data *rx,
|
|||
res = ieee80211_rx_mesh_data(rx->sdata, rx->sta, rx->skb);
|
||||
switch (res) {
|
||||
case RX_QUEUED:
|
||||
stats->last_rx = jiffies;
|
||||
stats->last_rate = sta_stats_encode_rate(status);
|
||||
return true;
|
||||
case RX_CONTINUE:
|
||||
break;
|
||||
|
|
@ -4999,11 +5006,6 @@ static bool ieee80211_invoke_fast_rx(struct ieee80211_rx_data *rx,
|
|||
drop:
|
||||
dev_kfree_skb(skb);
|
||||
|
||||
if (fast_rx->uses_rss)
|
||||
stats = this_cpu_ptr(rx->link_sta->pcpu_rx_stats);
|
||||
else
|
||||
stats = &rx->link_sta->rx_stats;
|
||||
|
||||
stats->dropped++;
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user