Commit cbf0dc37 authored by Dmitry Antipov's avatar Dmitry Antipov Committed by Johannes Berg
Browse files

wifi: mac80211: fix list iteration in ieee80211_add_virtual_monitor()



Since 'mon_list' of 'struct ieee80211_local' is RCU-protected and
an instances of 'struct ieee80211_sub_if_data' are linked there
via 'u.mntr.list' member, adjust the corresponding list iteration
in 'ieee80211_add_virtual_monitor()' accordingly.

Reported-by: default avatar <syzbot+bc1aabf52d0a31e91f96@syzkaller.appspotmail.com>
Closes: https://syzkaller.appspot.com/bug?extid=bc1aabf52d0a31e91f96


Fixes: a5aa46f1 ("wifi: mac80211: track MU-MIMO configuration on disabled interfaces")
Signed-off-by: default avatarDmitry Antipov <dmantipov@yandex.ru>
Link: https://patch.msgid.link/20251204130533.340069-1-dmantipov@yandex.ru


Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
parent 7623cc42
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1251,7 +1251,7 @@ int ieee80211_add_virtual_monitor(struct ieee80211_local *local,
	if (!creator_sdata) {
		struct ieee80211_sub_if_data *other;

		list_for_each_entry(other, &local->mon_list, list) {
		list_for_each_entry_rcu(other, &local->mon_list, u.mntr.list) {
			if (!other->vif.bss_conf.mu_mimo_owner)
				continue;