Search Linux Wireless

[PATCH] mt76: mt7615: fix CSA event format

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Fix format changes among the firmware versions.

Fixes: f9390c251868 ("mt76: mt7615: fix CSA notification for DBDC")
Signed-off-by: Ryder Lee <ryder.lee@xxxxxxxxxxxx>
---
@Felix, please help to fold this, if the previous one hasn't been pulled.
---
 drivers/net/wireless/mediatek/mt76/mt7615/mcu.c | 3 ++-
 drivers/net/wireless/mediatek/mt76/mt7615/mcu.h | 3 +--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/wireless/mediatek/mt76/mt7615/mcu.c b/drivers/net/wireless/mediatek/mt76/mt7615/mcu.c
index 44daee41aa6c..4ca0d8d4c536 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7615/mcu.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7615/mcu.c
@@ -375,12 +375,13 @@ mt7615_mcu_csa_finish(void *priv, u8 *mac, struct ieee80211_vif *vif)
 static void
 mt7615_mcu_rx_csa_notify(struct mt7615_dev *dev, struct sk_buff *skb)
 {
+	struct mt7615_phy *ext_phy = mt7615_ext_phy(dev);
 	struct mt76_phy *mphy = &dev->mt76.phy;
 	struct mt7615_mcu_csa_notify *c;
 
 	c = (struct mt7615_mcu_csa_notify *)skb->data;
 
-	if (c->band_idx && dev->mt76.phy2)
+	if (ext_phy && ext_phy->omac_mask & BIT_ULL(c->omac_idx))
 		mphy = dev->mt76.phy2;
 
 	ieee80211_iterate_active_interfaces_atomic(mphy->hw,
diff --git a/drivers/net/wireless/mediatek/mt76/mt7615/mcu.h b/drivers/net/wireless/mediatek/mt76/mt7615/mcu.h
index dbf72b1396c7..98c383e400a1 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7615/mcu.h
+++ b/drivers/net/wireless/mediatek/mt76/mt7615/mcu.h
@@ -181,8 +181,7 @@ struct mt7615_mcu_csa_notify {
 
 	u8 omac_idx;
 	u8 csa_count;
-	u8 band_idx;
-	u8 rsv;
+	u8 rsv[2];
 } __packed;
 
 struct mt7615_mcu_rdd_report {
-- 
2.18.0




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux