summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Huang <echuang@realtek.com>2025-06-18 15:46:46 +0300
committerPing-Ke Shih <pkshih@realtek.com>2025-06-24 09:38:27 +0300
commit640c27b2e0c504e5021b6b7635e3626781a45dba (patch)
treef6697c4316065c31a38822ba6d53e2f988c4e34a
parent8408366f61a7dddc1262ac74662b6238a22c447f (diff)
downloadlinux-640c27b2e0c504e5021b6b7635e3626781a45dba.tar.xz
wifi: rtw89: correct length for IE18/19 PHY report and IE parser
Correct the length when parsing with 2nd IE header and the length of IE18/19 PHY status report. These two IE contain PHY OFDM signal information and can be used for debug. Signed-off-by: Eric Huang <echuang@realtek.com> Signed-off-by: Ping-Ke Shih <pkshih@realtek.com> Link: https://patch.msgid.link/20250618124649.11436-4-pkshih@realtek.com
-rw-r--r--drivers/net/wireless/realtek/rtw89/core.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/net/wireless/realtek/rtw89/core.c b/drivers/net/wireless/realtek/rtw89/core.c
index 4026cda04ef6..d0d2ca31b376 100644
--- a/drivers/net/wireless/realtek/rtw89/core.c
+++ b/drivers/net/wireless/realtek/rtw89/core.c
@@ -1723,7 +1723,7 @@ static u16 rtw89_core_get_phy_status_ie_len(struct rtw89_dev *rtwdev,
},
[RTW89_CHIP_BE] = {
32, 40, 24, 24, 8, 8, 8, 8, VAR_LEN, 8, VAR_LEN, 176, VAR_LEN,
- VAR_LEN, VAR_LEN, VAR_LEN, VAR_LEN, VAR_LEN, 16, 24, VAR_LEN,
+ VAR_LEN, VAR_LEN, VAR_LEN, VAR_LEN, VAR_LEN, 88, 56, VAR_LEN,
VAR_LEN, VAR_LEN, 0, 24, 24, 24, 24, 32, 32, 32, 32
},
};
@@ -1918,6 +1918,8 @@ static int rtw89_core_rx_parse_phy_sts(struct rtw89_dev *rtwdev,
return -EINVAL;
pos = phy_ppdu->buf + PHY_STS_HDR_LEN;
+ if (phy_ppdu->hdr_2_en)
+ pos += PHY_STS_HDR_LEN;
end = phy_ppdu->buf + phy_ppdu->len;
while (pos < end) {
const struct rtw89_phy_sts_iehdr *iehdr = pos;