diff options
author | Lorenzo Bianconi <lorenzo.bianconi@redhat.com> | 2018-10-14 20:27:28 +0200 |
---|---|---|
committer | Felix Fietkau <nbd@nbd.name> | 2018-11-30 12:21:39 +0100 |
commit | 989582e50cbfd248707c0c3160f408dd4bd0c4bc (patch) | |
tree | dc098ef100ffc13f480b60ce44238692ad42ed2f /drivers/net/wireless/mediatek/mt76/mt76x2/usb_mcu.c | |
parent | cac97ed681db9891c74be91b54e6b550dc6afb03 (diff) | |
download | linux-stable-989582e50cbfd248707c0c3160f408dd4bd0c4bc.tar.gz linux-stable-989582e50cbfd248707c0c3160f408dd4bd0c4bc.tar.bz2 linux-stable-989582e50cbfd248707c0c3160f408dd4bd0c4bc.zip |
mt76x2u: align channel gain logic to mt76x2 one
Update vga tuning algorithm to the one used in mt76x2 driver
Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi@redhat.com>
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'drivers/net/wireless/mediatek/mt76/mt76x2/usb_mcu.c')
-rw-r--r-- | drivers/net/wireless/mediatek/mt76/mt76x2/usb_mcu.c | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/drivers/net/wireless/mediatek/mt76/mt76x2/usb_mcu.c b/drivers/net/wireless/mediatek/mt76/mt76x2/usb_mcu.c index a40aa838b6b2..d6e3e663dd8a 100644 --- a/drivers/net/wireless/mediatek/mt76/mt76x2/usb_mcu.c +++ b/drivers/net/wireless/mediatek/mt76/mt76x2/usb_mcu.c @@ -29,30 +29,6 @@ #define MT76U_MCU_DLM_OFFSET 0x110000 #define MT76U_MCU_ROM_PATCH_OFFSET 0x90000 -int mt76x2u_mcu_set_dynamic_vga(struct mt76x02_dev *dev, u8 channel, bool ap, - bool ext, int rssi, u32 false_cca) -{ - struct { - __le32 channel; - __le32 rssi_val; - __le32 false_cca_val; - } __packed __aligned(4) msg = { - .rssi_val = cpu_to_le32(rssi), - .false_cca_val = cpu_to_le32(false_cca), - }; - struct sk_buff *skb; - u32 val = channel; - - if (ap) - val |= BIT(31); - if (ext) - val |= BIT(30); - msg.channel = cpu_to_le32(val); - - skb = mt76_mcu_msg_alloc(dev, &msg, sizeof(msg)); - return mt76_mcu_send_msg(dev, skb, CMD_DYNC_VGA_OP, true); -} - static void mt76x2u_mcu_load_ivb(struct mt76x02_dev *dev) { mt76u_vendor_request(&dev->mt76, MT_VEND_DEV_MODE, |