Commit 69585ef9 authored by YueHaibing's avatar YueHaibing Committed by Felix Fietkau

mt76x0: pci: fix set external PA I/O current

Fixes gcc '-Wunused-but-set-variable' warning:

drivers/net/wireless/mediatek/mt76/mt76x0/pci.c: In function 'mt76x0e_register_device':
drivers/net/wireless/mediatek/mt76/mt76x0/pci.c:107:8: warning:
 variable 'data' set but not used [-Wunused-but-set-variable]

It seems correct value to write is 'data'

Fixes: 2b2cb40b ("mt76x0: pci: add hw initialization at bootstrap")
Acked-by: default avatarLorenzo Bianconi <lorenzo.bianconi@redhat.com>
Signed-off-by: default avatarYueHaibing <yuehaibing@huawei.com>
Signed-off-by: default avatarFelix Fietkau <nbd@nbd.name>
parent 5155938d
...@@ -115,12 +115,12 @@ static int mt76x0e_register_device(struct mt76x02_dev *dev) ...@@ -115,12 +115,12 @@ static int mt76x0e_register_device(struct mt76x02_dev *dev)
if (val & MT_EE_NIC_CONF_0_PA_IO_CURRENT) { if (val & MT_EE_NIC_CONF_0_PA_IO_CURRENT) {
u32 data; u32 data;
/* set external external PA I/O /* set external PA I/O
* current to 16mA * current to 16mA
*/ */
data = mt76_rr(dev, 0x11c); data = mt76_rr(dev, 0x11c);
val |= 0xc03; data |= 0xc03;
mt76_wr(dev, 0x11c, val); mt76_wr(dev, 0x11c, data);
} }
} }
......
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