Skip to content

Commit

Permalink
wifi: cfg80211: consume both probe response and beacon IEs
Browse files Browse the repository at this point in the history
[ Upstream commit f510bcc ]

When doing a channel switch, cfg80211_update_known_bss may be called
with a BSS where both proberesp_ies and beacon_ies is set. If that
happens, both need to be consumed.

Signed-off-by: Benjamin Berg <benjamin.berg@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://msgid.link/20231211085121.07a88656d7df.I0fe9fc599382de0eccf96455617e377d9c231966@changeid
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Stable-dep-of: 177fbbc ("wifi: cfg80211: detect stuck ECSA element in probe resp")
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
benzea authored and gregkh committed Feb 16, 2024
1 parent 3b48c9e commit 7af9b4d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion net/wireless/scan.c
Original file line number Diff line number Diff line change
Expand Up @@ -1746,7 +1746,9 @@ cfg80211_update_known_bss(struct cfg80211_registered_device *rdev,
new->pub.proberesp_ies);
if (old)
kfree_rcu((struct cfg80211_bss_ies *)old, rcu_head);
} else if (rcu_access_pointer(new->pub.beacon_ies)) {
}

if (rcu_access_pointer(new->pub.beacon_ies)) {
const struct cfg80211_bss_ies *old;

if (known->pub.hidden_beacon_bss &&
Expand Down

0 comments on commit 7af9b4d

Please sign in to comment.