diff options
author | Felix Fietkau <nbd@nbd.name> | 2024-03-09 17:44:42 +0100 |
---|---|---|
committer | Felix Fietkau <nbd@nbd.name> | 2024-05-02 12:44:49 +0200 |
commit | 7b9a5bcb8b2d39616a1bb41047d040e3e18786d8 (patch) | |
tree | e24b7b92ca0fec2b930300e782f1cfe3197de525 /drivers/net/wireless/mediatek | |
parent | 8886b6d681f28d838cb30ace8ce73f8b96bc927d (diff) |
wifi: mt76: mt7915: initialize rssi on adding stations
Improves initial rate selection after connecting
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'drivers/net/wireless/mediatek')
-rw-r--r-- | drivers/net/wireless/mediatek/mt76/mt7915/main.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/wireless/mediatek/mt76/mt7915/main.c b/drivers/net/wireless/mediatek/mt76/mt7915/main.c index 3709d18da0e6..49d5b459fb44 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7915/main.c +++ b/drivers/net/wireless/mediatek/mt76/mt7915/main.c @@ -744,6 +744,7 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif, struct mt7915_vif *mvif = (struct mt7915_vif *)vif->drv_priv; bool ext_phy = mvif->phy != &dev->phy; int ret, idx; + u32 addr; idx = mt76_wcid_alloc(dev->mt76.wcid_mask, MT7915_WTBL_STA); if (idx < 0) @@ -767,6 +768,9 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif, if (ret) return ret; + addr = mt7915_mac_wtbl_lmac_addr(dev, msta->wcid.idx, 30); + mt76_rmw_field(dev, addr, GENMASK(7, 0), 0xa0); + return mt7915_mcu_add_rate_ctrl(dev, vif, sta, false); } |