summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLorenzo Bianconi <lorenzo@kernel.org>2019-06-27 11:50:25 +0200
committerFelix Fietkau <nbd@nbd.name>2019-06-27 12:58:13 +0200
commitd923cf6bc38a7b174e6b813d1bf72c926539858c (patch)
tree7af7149335e749616717211b3eb38cbdb5b2043f
parenteda96044de274cbf7263834b5cecb51f1f7b0984 (diff)
downloadlinux-d923cf6bc38a7b174e6b813d1bf72c926539858c.tar.bz2
mt76: mt7615: fix sparse warnings: warning: cast from restricted __le16
Do not convert {tx,rx}_mcs_map to little-endian since it is already done by mac80211. This patch fix the following sparse warning: drivers/net/wireless/mediatek/mt76/mt7615/mcu.c:1497:25: sparse: warning: cast from restricted __le16 drivers/net/wireless/mediatek/mt76/mt7615/mcu.c:1499:25: sparse: warning: cast from restricted __le16 Fixes: 04b8e65922f6 ("mt76: add mac80211 driver for MT7615 PCIe-based chipsets") Fixes: 3ca0a6f6e9df ("mt7615: mcu: use standard signature for mt7615_mcu_msg_send") Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org> Signed-off-by: Felix Fietkau <nbd@nbd.name>
-rw-r--r--drivers/net/wireless/mediatek/mt76/mt7615/mcu.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/net/wireless/mediatek/mt76/mt7615/mcu.c b/drivers/net/wireless/mediatek/mt76/mt7615/mcu.c
index 8d01ee5df9a3..cdad2c8dc297 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7615/mcu.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7615/mcu.c
@@ -1393,10 +1393,8 @@ int mt7615_mcu_set_ht_cap(struct mt7615_dev *dev, struct ieee80211_vif *vif,
sta_vht->tag = cpu_to_le16(STA_REC_VHT);
sta_vht->len = cpu_to_le16(sizeof(*sta_vht));
sta_vht->vht_cap = cpu_to_le32(sta->vht_cap.cap);
- sta_vht->vht_rx_mcs_map =
- cpu_to_le16(sta->vht_cap.vht_mcs.rx_mcs_map);
- sta_vht->vht_tx_mcs_map =
- cpu_to_le16(sta->vht_cap.vht_mcs.tx_mcs_map);
+ sta_vht->vht_rx_mcs_map = sta->vht_cap.vht_mcs.rx_mcs_map;
+ sta_vht->vht_tx_mcs_map = sta->vht_cap.vht_mcs.tx_mcs_map;
}
ret = __mt76_mcu_send_msg(&dev->mt76, MCU_EXT_CMD_STA_REC_UPDATE,