Commit ff434cc1 authored by StanleyYP Wang's avatar StanleyYP Wang Committed by Felix Fietkau

wifi: mt76: mt7915: also MT7981 is 3T3R but nss2 on 5 GHz band

Just like MT7916 also MT7981 can handle 3T3R DBDC frontend and should
hence be included in the corresponding conditional expression in the
driver. Add it.

Fixes: 6bad146d ("wifi: mt76: mt7915: add support for MT7981")
Signed-off-by: default avatarStanleyYP Wang <StanleyYP.Wang@mediatek.com>
Signed-off-by: default avatarDaniel Golle <daniel@makrotopia.org>
Signed-off-by: default avatarFelix Fietkau <nbd@nbd.name>
parent 3531c72a
...@@ -1059,8 +1059,9 @@ mt7915_set_antenna(struct ieee80211_hw *hw, u32 tx_ant, u32 rx_ant) ...@@ -1059,8 +1059,9 @@ mt7915_set_antenna(struct ieee80211_hw *hw, u32 tx_ant, u32 rx_ant)
phy->mt76->antenna_mask = tx_ant; phy->mt76->antenna_mask = tx_ant;
/* handle a variant of mt7916 which has 3T3R but nss2 on 5 GHz band */ /* handle a variant of mt7916/mt7981 which has 3T3R but nss2 on 5 GHz band */
if (is_mt7916(&dev->mt76) && band && hweight8(tx_ant) == max_nss) if ((is_mt7916(&dev->mt76) || is_mt7981(&dev->mt76)) &&
band && hweight8(tx_ant) == max_nss)
phy->mt76->chainmask = (dev->chainmask >> chainshift) << chainshift; phy->mt76->chainmask = (dev->chainmask >> chainshift) << chainshift;
else else
phy->mt76->chainmask = tx_ant << (chainshift * band); phy->mt76->chainmask = tx_ant << (chainshift * band);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment