[PATCH 27/28] wifi: mt76: mt7925: clear the MLD BSS tag on deactivate
Emery Hsin
emery.hsin at mediatek.com
Mon Nov 9 19:12:43 PST 2026
Add an enable flag to mt7925_mcu_bss_mld_tlv(). On deactivate clear
the MLD fields, otherwise the firmware keeps the hybrid-MLO OM remap
and the deflink's TX OWN_MAC stays mapped to a dead MLO primary OMAC
after reconnect.
Signed-off-by: Emery Hsin <emery.hsin at mediatek.com>
---
drivers/net/wireless/mediatek/mt76/mt7925/mcu.c | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
diff --git a/drivers/net/wireless/mediatek/mt76/mt7925/mcu.c b/drivers/net/wireless/mediatek/mt76/mt7925/mcu.c
index d02242870115..588328a01dc8 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7925/mcu.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7925/mcu.c
@@ -3263,7 +3263,7 @@ mt7925_mcu_bss_bmc_tlv(struct sk_buff *skb, struct mt792x_phy *phy,
static void
mt7925_mcu_bss_mld_tlv(struct sk_buff *skb,
- struct ieee80211_bss_conf *link_conf)
+ struct ieee80211_bss_conf *link_conf, bool enable)
{
struct ieee80211_vif *vif = link_conf->vif;
struct mt792x_bss_conf *mconf = mt792x_link_conf_to_mconf(link_conf);
@@ -3275,10 +3275,14 @@ mt7925_mcu_bss_mld_tlv(struct sk_buff *skb,
bool is_hybrid;
bool is_supported_ap = false;
- is_mld = ieee80211_vif_is_mld(link_conf->vif) ||
- (hweight16(mvif->valid_links) > 1);
+ /* On deactivate clear the MLD classification. Otherwise the FW
+ * keeps the hybrid-MLO OM remap and the deflink's TX OWN_MAC stays
+ * mapped to a dead MLO primary OMAC after reconnect.
+ */
+ is_mld = enable && (ieee80211_vif_is_mld(link_conf->vif) ||
+ (hweight16(mvif->valid_links) > 1));
/* three links means hybrid MLO */
- is_hybrid = hweight16(mvif->valid_links) >= 3 &&
+ is_hybrid = enable && hweight16(mvif->valid_links) >= 3 &&
(phy->chip_cap & BIT(MT792x_CHIP_CAP_MLO_HYBRID_EN));
tlv = mt76_connac_mcu_add_tlv(skb, UNI_BSS_INFO_MLD, sizeof(*mld));
@@ -3450,7 +3454,7 @@ int mt7925_mcu_add_bss_info_sta(struct mt792x_phy *phy,
mt7925_mcu_bss_sec_tlv(skb, link_conf);
mt7925_mcu_bss_bmc_tlv(skb, phy, ctx, link_conf);
mt7925_mcu_bss_qos_tlv(skb, link_conf);
- mt7925_mcu_bss_mld_tlv(skb, link_conf);
+ mt7925_mcu_bss_mld_tlv(skb, link_conf, enable);
mt7925_mcu_bss_ifs_tlv(skb, link_conf);
if (link_conf->he_support) {
--
2.45.2
More information about the Linux-mediatek
mailing list