rtw88: pci: remove set but not used variable 'ip_sel'
authorYueHaibing <yuehaibing@huawei.com>
Fri, 26 Jul 2019 14:20:18 +0000 (22:20 +0800)
committerKalle Valo <kvalo@codeaurora.org>
Tue, 6 Aug 2019 12:38:13 +0000 (15:38 +0300)
Fixes gcc '-Wunused-but-set-variable' warning:

drivers/net/wireless/realtek/rtw88/pci.c: In function 'rtw_pci_phy_cfg':
drivers/net/wireless/realtek/rtw88/pci.c:993:6: warning:
 variable 'ip_sel' set but not used [-Wunused-but-set-variable]

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/realtek/rtw88/pci.c

index 23dd06afef3d872504ed6b24c54eb27e01d0938f..c56251539874e75a27313ebbd3d7163a79c15dee 100644 (file)
@@ -990,7 +990,6 @@ static void rtw_pci_phy_cfg(struct rtw_dev *rtwdev)
        u16 cut;
        u16 value;
        u16 offset;
-       u16 ip_sel;
        int i;
 
        cut = BIT(0) << rtwdev->hal.cut_version;
@@ -1003,7 +1002,6 @@ static void rtw_pci_phy_cfg(struct rtw_dev *rtwdev)
                        break;
                offset = para->offset;
                value = para->value;
-               ip_sel = para->ip_sel;
                if (para->ip_sel == RTW_IP_SEL_PHY)
                        rtw_mdio_write(rtwdev, offset, value, true);
                else
@@ -1018,7 +1016,6 @@ static void rtw_pci_phy_cfg(struct rtw_dev *rtwdev)
                        break;
                offset = para->offset;
                value = para->value;
-               ip_sel = para->ip_sel;
                if (para->ip_sel == RTW_IP_SEL_PHY)
                        rtw_mdio_write(rtwdev, offset, value, false);
                else