summaryrefslogtreecommitdiff
path: root/net/mac80211
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@nbd.name>2022-12-14 16:03:26 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2023-01-24 09:24:32 +0300
commit10644c9828c8e1024e4a41dd2efd707e748f7fbc (patch)
treee805abf9955774bc7bb7d8d8c64cf30b9c2bfb4b /net/mac80211
parent1590cee5342ebdb31c48448736081201daad9828 (diff)
downloadlinux-10644c9828c8e1024e4a41dd2efd707e748f7fbc.tar.xz
wifi: mac80211: fix MLO + AP_VLAN check
commit f216033d770f7ca0eda491fe01a9f02e7af59576 upstream. Instead of preventing adding AP_VLAN to MLO enabled APs, this check was preventing adding more than one 4-addr AP_VLAN regardless of the MLO status. Fix this by adding missing extra checks. Fixes: ae960ee90bb1 ("wifi: mac80211: prevent VLANs on MLDs") Signed-off-by: Felix Fietkau <nbd@nbd.name> Link: https://lore.kernel.org/r/20221214130326.37756-1-nbd@nbd.name Cc: stable@vger.kernel.org Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net/mac80211')
-rw-r--r--net/mac80211/iface.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/net/mac80211/iface.c b/net/mac80211/iface.c
index 46f08ec5ed76..8375900f210e 100644
--- a/net/mac80211/iface.c
+++ b/net/mac80211/iface.c
@@ -364,7 +364,9 @@ static int ieee80211_check_concurrent_iface(struct ieee80211_sub_if_data *sdata,
/* No support for VLAN with MLO yet */
if (iftype == NL80211_IFTYPE_AP_VLAN &&
- nsdata->wdev.use_4addr)
+ sdata->wdev.use_4addr &&
+ nsdata->vif.type == NL80211_IFTYPE_AP &&
+ nsdata->vif.valid_links)
return -EOPNOTSUPP;
/*