Skip to content

Commit ea92854

Browse files
ilanpeer2jmberg-intel
authored andcommitted
wifi: mac80211: Fix HE capabilities element check
The element data length check did not account for the extra octet used for the extension ID. Fix it. Signed-off-by: Ilan Peer <[email protected]> Signed-off-by: Miri Korenblit <[email protected]> Link: https://patch.msgid.link/20250907115109.8da0012e2286.I8c0c69a0011f7153c13b365b14dfef48cfe7c3e3@changeid Signed-off-by: Johannes Berg <[email protected]>
1 parent 906a5a8 commit ea92854

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

net/mac80211/mlme.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5725,7 +5725,7 @@ static u8 ieee80211_max_rx_chains(struct ieee80211_link_data *link,
57255725
he_cap_elem = cfg80211_find_ext_elem(WLAN_EID_EXT_HE_CAPABILITY,
57265726
ies->data, ies->len);
57275727

5728-
if (!he_cap_elem || he_cap_elem->datalen < sizeof(*he_cap))
5728+
if (!he_cap_elem || he_cap_elem->datalen < sizeof(*he_cap) + 1)
57295729
return chains;
57305730

57315731
/* skip one byte ext_tag_id */

0 commit comments

Comments
 (0)