diff options
author | Felix Fietkau <nbd@nbd.name> | 2020-02-25 13:15:33 +0100 |
---|---|---|
committer | Felix Fietkau <nbd@nbd.name> | 2020-03-17 17:13:59 +0100 |
commit | 1a7d3f47931ff721ac4459a6166db99e33fd28b7 (patch) | |
tree | dc7466f2cb8455ccb7ca6a7488b5aab30192a068 /drivers/net/wireless/mediatek/mt76/mt7615/main.c | |
parent | mt76: mt76u: rely only on data buffer for usb control messagges (diff) | |
download | linux-1a7d3f47931ff721ac4459a6166db99e33fd28b7.tar.xz linux-1a7d3f47931ff721ac4459a6166db99e33fd28b7.zip |
mt76: mt7615: fix antenna mask initialization in DBDC mode
Update wiphy available antenna mask, and fix chainmask setting on 3x3 hardware
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'drivers/net/wireless/mediatek/mt76/mt7615/main.c')
-rw-r--r-- | drivers/net/wireless/mediatek/mt76/mt7615/main.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/net/wireless/mediatek/mt76/mt7615/main.c b/drivers/net/wireless/mediatek/mt76/mt7615/main.c index 01194ed79869..7edd5e739b2d 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7615/main.c +++ b/drivers/net/wireless/mediatek/mt76/mt7615/main.c @@ -686,7 +686,13 @@ mt7615_set_antenna(struct ieee80211_hw *hw, u32 tx_ant, u32 rx_ant) mutex_lock(&dev->mt76.mutex); phy->mt76->antenna_mask = tx_ant; - phy->chainmask = ext_phy ? tx_ant << 2 : tx_ant; + if (ext_phy) { + if (dev->chainmask == 0xf) + tx_ant <<= 2; + else + tx_ant <<= 1; + } + phy->chainmask = tx_ant; mt76_set_stream_caps(&dev->mt76, true); |