From: Felix Fietkau <nbd@nbd.name>
To: linux-wireless@vger.kernel.org
Cc: stable+noautosel@kernel.org
Subject: [PATCH mt76-next 09/17] wifi: mt76: mt7925: send the MLO ROC only for a station vif
Date: Sat, 21 Nov 2026 13:09:18 +0100 [thread overview]
Message-ID: <20261121120926.3603979-9-nbd@nbd.name> (raw)
In-Reply-To: <20261121120926.3603979-1-nbd@nbd.name>
The MLO ROC asks the firmware for channel time on the links of an MLSR
non-AP MLD. mt7925_change_vif_links() also sends it for an AP MLD.
mac80211 adds an AP link without a channel, so the second ADD_LINK of an
AP MLD hits WARN_ON_ONCE(!links[i].chan) in mt7925_mcu_set_mlo_roc().
The ROC then fails, and with it the ADD_LINK, so an AP MLD cannot get a
second link.
Only send the MLO ROC for a station interface, which includes a P2P
client. Check the type before mt7925_mac_set_links() looks up the link
conf of the default link, which an AP MLD can remove while other links
stay. An mt7925 AP MLD can then add more than one link. Whether the
firmware runs such an AP MLD correctly is untested.
Fixes: 69acd6d910b0 ("wifi: mt76: mt7925: add mt7925_change_vif_links")
Cc: <stable+noautosel@kernel.org> # enables untested AP MLD links
Signed-off-by: Felix Fietkau <nbd@nbd.name>
---
drivers/net/wireless/mediatek/mt76/mt7925/main.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/net/wireless/mediatek/mt76/mt7925/main.c b/drivers/net/wireless/mediatek/mt76/mt7925/main.c
index 27a622beb147..d99d86bf5be8 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7925/main.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7925/main.c
@@ -1446,7 +1446,8 @@ int mt7925_mac_sta_event(struct mt76_dev *mdev, struct ieee80211_vif *vif,
link_sta = mt792x_sta_to_link_sta(vif, sta,
msta->deflink_id);
- mt7925_mac_set_links(mdev, vif);
+ if (vif->type == NL80211_IFTYPE_STATION)
+ mt7925_mac_set_links(mdev, vif);
}
mt7925_mac_link_sta_assoc(mdev, vif, link_sta);
@@ -2644,7 +2645,8 @@ mt7925_change_vif_links(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
added |= BIT(link_id);
- if (mconf != &mvif->bss_conf) {
+ if (mconf != &mvif->bss_conf &&
+ vif->type == NL80211_IFTYPE_STATION) {
err = mt7925_set_mlo_roc(phy, &mvif->bss_conf,
vif->active_links);
if (err < 0)
--
2.47.3
next prev parent reply other threads:[~2026-11-21 12:09 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-21 12:09 [PATCH mt76-next 01/17] wifi: mt76: mt7996: name a new secondary link to the firmware first Felix Fietkau
2026-11-21 12:09 ` [PATCH mt76-next 02/17] wifi: mt76: add a helper to point the TXQs of a station at a wcid Felix Fietkau
2026-11-21 12:09 ` [PATCH mt76-next 03/17] wifi: mt76: mt7925: move the default link to a remaining link Felix Fietkau
2026-11-21 12:09 ` [PATCH mt76-next 04/17] wifi: mt76: mt7925: keep the deflink wcid index until station removal Felix Fietkau
2026-11-21 12:09 ` [PATCH mt76-next 05/17] wifi: mt76: mt792x: look up the TX links under RCU Felix Fietkau
2026-11-21 12:09 ` [PATCH mt76-next 06/17] wifi: mt76: mt7925: read the links under RCU in the IPv6 notifier Felix Fietkau
2026-11-21 12:09 ` [PATCH mt76-next 07/17] wifi: mt76: mt7925: abort a ROC on the BSS that requested it Felix Fietkau
2026-11-21 12:09 ` [PATCH mt76-next 08/17] wifi: mt76: mt7925: take the link conf of a removed link from old[] Felix Fietkau
2026-11-21 12:09 ` Felix Fietkau [this message]
2026-11-21 12:09 ` [PATCH mt76-next 10/17] wifi: mt76: mt7996: send the Beacon rate table again after a full reset Felix Fietkau
2026-11-21 12:09 ` [PATCH mt76-next 11/17] wifi: mt76: mt7996: restore the operating channel after an L1 SER Felix Fietkau
2026-11-21 12:09 ` [PATCH mt76-next 12/17] wifi: mt76: reset the DFS state of a phy at a full reset Felix Fietkau
2026-11-21 12:09 ` [PATCH mt76-next 13/17] wifi: mt76: mt7996: abort a background CAC " Felix Fietkau
2026-11-21 12:09 ` [PATCH mt76-next 14/17] wifi: mt76: mt7915: " Felix Fietkau
2026-11-21 12:09 ` [PATCH mt76-next 15/17] wifi: mt76: mt7996: clear the airtime counts with the WTBL counters Felix Fietkau
2026-11-21 12:09 ` [PATCH mt76-next 16/17] wifi: mt76: mt7996: drop the host WTBL write of a fixed GI Felix Fietkau
2026-11-21 12:09 ` [PATCH mt76-next 17/17] wifi: mt76: mt7925: don't reset the USB device on probe Felix Fietkau
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261121120926.3603979-9-nbd@nbd.name \
--to=nbd@nbd.name \
--cc=linux-wireless@vger.kernel.org \
--cc=stable+noautosel@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox