[PATCH] mt76: mt7915: fix WMM index on DBDC cards

Subsystems: mediatek mt76 wireless lan driver, the rest

STALE1796d

2 messages, 2 authors, 2021-09-09 · open the first message on its own page

[PATCH] mt76: mt7915: fix WMM index on DBDC cards

From: Felix Fietkau <nbd@nbd.name>
Date: 2021-09-08 15:58:50

WMM index range needs to be split between both PHYs if a second PHY exists.
The condition for that was accidentally written as checking if the vif PHY
is the secondary one

Signed-off-by: Felix Fietkau <nbd@nbd.name>
---
 drivers/net/wireless/mediatek/mt76/mt7915/main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/wireless/mediatek/mt76/mt7915/main.c b/drivers/net/wireless/mediatek/mt76/mt7915/main.c
index 748ea70ea12e..a19e68668c65 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7915/main.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7915/main.c
@@ -215,7 +215,7 @@ static int mt7915_add_interface(struct ieee80211_hw *hw,
 	mvif->phy = phy;
 	mvif->band_idx = ext_phy;
 
-	if (ext_phy)
+	if (dev->mt76.phy2)
 		mvif->wmm_idx = ext_phy * (MT7915_MAX_WMM_SETS / 2) +
 				mvif->idx % (MT7915_MAX_WMM_SETS / 2);
 	else
-- 
2.30.1

Re: [PATCH] mt76: mt7915: fix WMM index on DBDC cards

From: Lorenzo Bianconi <lorenzo@kernel.org>
Date: 2021-09-09 08:10:23

WMM index range needs to be split between both PHYs if a second PHY exists.
The condition for that was accidentally written as checking if the vif PHY
is the secondary one
We need to add the following Fixes tag here:

Fixes: e57b7901469fc ("mt76: add mac80211 driver for MT7915 PCIe-based chipsets")

Regards,
Lorenzo
quoted hunk
Signed-off-by: Felix Fietkau <nbd@nbd.name>
---
 drivers/net/wireless/mediatek/mt76/mt7915/main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/wireless/mediatek/mt76/mt7915/main.c b/drivers/net/wireless/mediatek/mt76/mt7915/main.c
index 748ea70ea12e..a19e68668c65 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7915/main.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7915/main.c
@@ -215,7 +215,7 @@ static int mt7915_add_interface(struct ieee80211_hw *hw,
 	mvif->phy = phy;
 	mvif->band_idx = ext_phy;
 
-	if (ext_phy)
+	if (dev->mt76.phy2)
 		mvif->wmm_idx = ext_phy * (MT7915_MAX_WMM_SETS / 2) +
 				mvif->idx % (MT7915_MAX_WMM_SETS / 2);
 	else
-- 
2.30.1
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help