From 7f4a3b710a983981afc813defab0b7bd4a9300ec Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Wed, 29 Jul 2026 18:07:36 +0200 Subject: [PATCH] wifi: mt76: mt7915: send the STA_REC before the VoW group setup __mt7915_mcu_add_sta() issued the SET_DRR_CTRL command that assigns the VoW BSS group before sending the STA_REC that instantiates the station in the firmware, and dropped the STA_REC skb unsent if that command was rejected. On mt7996 the same ordering made client mode association fail once the command occupying that slot started to depend on the station record already existing. Signed-off-by: Felix Fietkau --- mt7915/mcu.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/mt7915/mcu.c b/mt7915/mcu.c index e19ffc70..5327c1ff 100644 --- a/mt7915/mcu.c +++ b/mt7915/mcu.c @@ -1790,11 +1790,6 @@ int __mt7915_mcu_add_sta(struct mt7915_dev *dev, struct ieee80211_vif *vif, mt7915_mcu_sta_bfee_tlv(dev, skb, vif, sta); } - ret = mt7915_mcu_add_group(dev, vif, sta); - if (ret) { - dev_kfree_skb(skb); - return ret; - } out: ret = mt76_connac_mcu_sta_wed_update(&dev->mt76, skb); if (ret) { @@ -1802,8 +1797,14 @@ out: return ret; } - return mt76_mcu_skb_send_msg(&dev->mt76, skb, - MCU_EXT_CMD(STA_REC_UPDATE), true); + ret = mt76_mcu_skb_send_msg(&dev->mt76, skb, + MCU_EXT_CMD(STA_REC_UPDATE), true); + if (ret || conn_state == CONN_STATE_DISCONNECT) + return ret; + + mt7915_mcu_add_group(dev, vif, sta); + + return 0; } int mt7915_mcu_wed_enable_rx_stats(struct mt7915_dev *dev)