wifi: ath12k: Fix TX status reporting to mac80211 when offload is enabled
authorNithyanantham Paramasivam <nithyanantham.paramasivam@oss.qualcomm.com>
Fri, 18 Jul 2025 02:55:12 +0000 (08:25 +0530)
committerJeff Johnson <jeff.johnson@oss.qualcomm.com>
Sat, 19 Jul 2025 16:14:45 +0000 (09:14 -0700)
commit981050b918fc4c36e0ef3bd7392b39d7304ef09b
treee55c212418b5feaaa565a7a474571d56fb419e00
parent192c8e9a131f1772a635c3c5df4cb592bd7b3e8b
wifi: ath12k: Fix TX status reporting to mac80211 when offload is enabled

Currently, the ath12k driver supports only the native Wi-Fi
frame format. In this mode, the ieee80211_tx_status() function
works correctly to report transmission status to mac80211, as
it retrieves station information using sta_info_get_by_addrs().

However, this method is not applicable for Ethernet-converted
packets, since sta_info_get_by_addrs() cannot extract station
information from such formats.

Retrieve station information using ath12k_peer_find_by_id() to
support all frame formats, including native Wi-Fi, raw, and Ethernet.
Report transmission status using ieee80211_tx_status_ext(), and
include rate information as part of the datapath TX status report.

Tested-on: QCN9274 hw2.0 PCI WLAN.WBE.1.4.1-00217-QCAHKSWPL_SILICONZ-1
Tested-on: WCN7850 hw2.0 PCI WLAN.HMT.1.0.c5-00481-QCAHMTSWPL_V1.0_V2.0_SILICONZ-3

Signed-off-by: Nithyanantham Paramasivam <nithyanantham.paramasivam@oss.qualcomm.com>
Reviewed-by: Vasanthakumar Thiagarajan <vasanthakumar.thiagarajan@oss.qualcomm.com>
Link: https://patch.msgid.link/20250718025513.32982-3-nithyanantham.paramasivam@oss.qualcomm.com
[changed instances of { 0 } to {}]
Signed-off-by: Jeff Johnson <jeff.johnson@oss.qualcomm.com>
drivers/net/wireless/ath/ath12k/dp_tx.c