blob: 7ea07b3d59b5d5adf41b06b4bea82b514ec90ba2 [file] [log] [blame]
developer1f55fcf2024-10-17 14:52:33 +08001From 144595bc970deaff03247b457a43cf8685328c97 Mon Sep 17 00:00:00 2001
developer05f3b2b2024-08-19 19:17:34 +08002From: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
3Date: Tue, 11 Jun 2024 17:04:00 +0800
developer1f55fcf2024-10-17 14:52:33 +08004Subject: [PATCH 140/193] mtk: mt76: mt7996: add per-link txpower config
developer05f3b2b2024-08-19 19:17:34 +08005
6Signed-off-by: StanleyYP Wang <StanleyYP.Wang@mediatek.com>
7---
8 mt7996/main.c | 4 ++--
9 1 file changed, 2 insertions(+), 2 deletions(-)
10
11diff --git a/mt7996/main.c b/mt7996/main.c
developer1f55fcf2024-10-17 14:52:33 +080012index 5207716..cc0c5ac 100644
developer05f3b2b2024-08-19 19:17:34 +080013--- a/mt7996/main.c
14+++ b/mt7996/main.c
developer1f55fcf2024-10-17 14:52:33 +080015@@ -1015,7 +1015,7 @@ out:
developer05f3b2b2024-08-19 19:17:34 +080016 }
17
18 int mt7996_get_txpower(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
19- int *dbm)
20+ unsigned int link_id, int *dbm)
21 {
22 struct mt7996_vif *mvif = (struct mt7996_vif *)vif->drv_priv;
23 struct mt7996_bss_conf *mconf;
developer1f55fcf2024-10-17 14:52:33 +080024@@ -1024,7 +1024,7 @@ int mt7996_get_txpower(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
developer05f3b2b2024-08-19 19:17:34 +080025 int delta;
26
27 mutex_lock(&dev->mt76.mutex);
28- mconf = mconf_dereference_protected(mvif, mvif->master_link_id);
29+ mconf = mconf_dereference_protected(mvif, link_id);
30 if (!mconf || !mconf->phy) {
31 *dbm = 0;
32 goto out;
33--
developerd0c89452024-10-11 16:53:27 +0800342.45.2
developer05f3b2b2024-08-19 19:17:34 +080035