blob: b6889a4a6f5159f141084b75f73ab5bd43b66fc4 [file] [log] [blame]
developera43cc482023-04-17 15:57:28 +08001From 69b6daca7311f3836c73515d34f2fdb9f3a65b65 Mon Sep 17 00:00:00 2001
developer6a1998b2022-12-08 18:09:45 +08002From: Peter Chiu <chui-hao.chiu@mediatek.com>
3Date: Sun, 24 Apr 2022 10:07:00 +0800
developera43cc482023-04-17 15:57:28 +08004Subject: [PATCH 1015/1032] wifi: mt76: mt7915: init rssi in WTBL when add
developer78848c62023-04-06 13:44:00 +08005 station
developer6a1998b2022-12-08 18:09:45 +08006
7---
8 mt7915/main.c | 4 ++++
9 1 file changed, 4 insertions(+)
10
11diff --git a/mt7915/main.c b/mt7915/main.c
developera43cc482023-04-17 15:57:28 +080012index 2fba3e8..a53cc19 100644
developer6a1998b2022-12-08 18:09:45 +080013--- a/mt7915/main.c
14+++ b/mt7915/main.c
developer78848c62023-04-06 13:44:00 +080015@@ -694,6 +694,7 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
developerb8853042023-02-17 11:50:45 +080016 struct mt7915_phy *phy = ext_phy ? mt7915_ext_phy(dev) : &dev->phy;
developer6a1998b2022-12-08 18:09:45 +080017 #endif
18 int ret, idx;
19+ u32 addr;
20
21 idx = mt76_wcid_alloc(dev->mt76.wcid_mask, MT7915_WTBL_STA);
22 if (idx < 0)
developera43cc482023-04-17 15:57:28 +080023@@ -718,6 +719,9 @@ int mt7915_mac_sta_add(struct mt76_dev *mdev, struct ieee80211_vif *vif,
developer6a1998b2022-12-08 18:09:45 +080024 if (ret)
25 return ret;
26
27+ addr = mt7915_mac_wtbl_lmac_addr(dev, msta->wcid.idx, 30);
28+ mt76_rmw_field(dev, addr, GENMASK(7, 0), 0xa0);
29+
30 #ifdef CONFIG_MTK_VENDOR
31 mt7915_vendor_amnt_sta_remove(mvif->phy, sta);
32 #endif
33--
developera43cc482023-04-17 15:57:28 +0800342.18.0
developer6a1998b2022-12-08 18:09:45 +080035