[PATCH wireless] wifi: mt76: mt7996: send no MLD group in a non-MLD link operation
Piotr Kubik
piotr at kubik.pl
Tue Oct 20 03:31:26 PDT 2026
The driver keeps the link of an AP after the AP stops, and it sends
the link operation again when the AP starts. The command carries the
MLD group and the remap index of the vif. Only an MLD vif gets these
indexes, so a non-MLD AP sends 0 for both. When an MLD on the same
device holds group 0 and remap 0, for example the station MLD of a
repeater, the firmware takes the address of the AP for that MLD. The
station then sends its data with the BSSID of the AP as transmitter
address, and its AP drops the station for inactivity.
Send 0xff for both indexes for a non-MLD vif, as the BSS MLD TLV of
mt7996_mcu_add_bss_info() already does.
Fixes: e7ec71d9f8fa ("wifi: mt76: mt7996: Add mcu APIs to enable/disable vif links.")
Cc: stable at vger.kernel.org
Signed-off-by: Piotr Kubik <piotr at kubik.pl>
---
drivers/net/wireless/mediatek/mt76/mt7996/mcu.c | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/drivers/net/wireless/mediatek/mt76/mt7996/mcu.c b/drivers/net/wireless/mediatek/mt76/mt7996/mcu.c
index cd7587c..c0b467f 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7996/mcu.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7996/mcu.c
@@ -2701,8 +2701,13 @@ int mt7996_mcu_mld_link_oper(struct mt7996_dev *dev,
mld_op->link_operation = add;
mld_op->own_mld_id = link->mld_idx;
mld_op->link_id = link_conf->link_id;
- mld_op->group_mld_id = add ? mvif->mld_group_idx : 0xff;
- mld_op->remap_idx = add ? mvif->mld_remap_idx : 0xff;
+ if (add && ieee80211_vif_is_mld(vif)) {
+ mld_op->group_mld_id = mvif->mld_group_idx;
+ mld_op->remap_idx = mvif->mld_remap_idx;
+ } else {
+ mld_op->group_mld_id = 0xff;
+ mld_op->remap_idx = 0xff;
+ }
memcpy(mld_op->mac_addr, vif->addr, ETH_ALEN);
return mt76_mcu_skb_send_msg(&dev->mt76, skb,
More information about the Linux-mediatek
mailing list