From d179d224cecd0f331c759b0f076e8b69779ebc20 Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Tue, 27 Oct 2026 13:24:55 +0000 Subject: [PATCH] mac80211: compute the links of each AP VLAN on its own At an AP link change, ieee80211_update_apvlan_links() carried the link mask of one 4-address AP VLAN over to the next. With two Multi-AP backhaul MLDs on different link sets, the second VLAN lost links that its station holds, and mac80211 removed them from the station. Signed-off-by: Felix Fietkau --- ...mpute-the-links-of-each-AP-VLAN-on-i.patch | 34 +++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 package/kernel/mac80211/patches/subsys/460-wifi-mac80211-compute-the-links-of-each-AP-VLAN-on-i.patch diff --git a/package/kernel/mac80211/patches/subsys/460-wifi-mac80211-compute-the-links-of-each-AP-VLAN-on-i.patch b/package/kernel/mac80211/patches/subsys/460-wifi-mac80211-compute-the-links-of-each-AP-VLAN-on-i.patch new file mode 100644 index 00000000000..4c5597ebabd --- /dev/null +++ b/package/kernel/mac80211/patches/subsys/460-wifi-mac80211-compute-the-links-of-each-AP-VLAN-on-i.patch @@ -0,0 +1,34 @@ +From: Felix Fietkau +Date: Sat, 24 Oct 2026 04:00:57 +0200 +Subject: [PATCH] wifi: mac80211: compute the links of each AP VLAN on its own + +ieee80211_update_apvlan_links() narrows one link mask for every +4-address AP VLAN of the AP with the links of that VLAN's station, and +never resets it between VLANs. Each VLAN after the first thus gets only +the links that the stations of all earlier VLANs hold as well. A link +change of an AP with two WDS MLD stations on different link sets takes +links from the second VLAN that its station uses. Reachable via +ieee80211_vif_update_links() on an AP link add or removal. + +Start from the links of the AP for each VLAN. + +Fixes: 469d5d5a3b7a ("wifi: mac80211: synchronize valid links for WDS AP_VLAN interfaces") +Signed-off-by: Felix Fietkau + +--- a/net/mac80211/link.c ++++ b/net/mac80211/link.c +@@ -17,13 +17,13 @@ static void ieee80211_update_apvlan_link + unsigned long rem = ~sdata->vif.valid_links & + GENMASK(IEEE80211_MLD_MAX_NUM_LINKS - 1, 0); + struct ieee80211_local *local = sdata->local; +- unsigned long add = sdata->vif.valid_links; + struct wiphy *wiphy = local->hw.wiphy; + struct ieee80211_sub_if_data *vlan; + struct ieee80211_link_data *link; + struct sta_info *sta; + + list_for_each_entry(vlan, &sdata->u.ap.vlans, u.vlan.list) { ++ unsigned long add = sdata->vif.valid_links; + int link_id; + + if (vlan->wdev.use_4addr) {