From 3ba6baf64b9a967d731b9c93e3dcd64bd82db83d Mon Sep 17 00:00:00 2001 From: Zheng Yongjun Date: Mon, 21 Sep 2020 20:18:41 +0800 Subject: net: natsemi: Remove set but not used variable MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fixes gcc '-Wunused-but-set-variable' warning: drivers/net/ethernet/natsemi/ns83820.c: In function ns83820_get_link_ksettings: drivers/net/ethernet/natsemi/ns83820.c:1210:11: warning: variable ‘tanar’ set but not used [-Wunused-but-set-variable] `tanar` is never used, so remove it. Signed-off-by: Zheng Yongjun Signed-off-by: David S. Miller --- drivers/net/ethernet/natsemi/ns83820.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/natsemi/ns83820.c b/drivers/net/ethernet/natsemi/ns83820.c index f59f96fbbef6..4c1f53339019 100644 --- a/drivers/net/ethernet/natsemi/ns83820.c +++ b/drivers/net/ethernet/natsemi/ns83820.c @@ -1204,7 +1204,7 @@ static int ns83820_get_link_ksettings(struct net_device *ndev, struct ethtool_link_ksettings *cmd) { struct ns83820 *dev = PRIV(ndev); - u32 cfg, tanar, tbicr; + u32 cfg, tbicr; int fullduplex = 0; u32 supported; @@ -1223,7 +1223,7 @@ static int ns83820_get_link_ksettings(struct net_device *ndev, /* read current configuration */ cfg = readl(dev->base + CFG) ^ SPDSTS_POLARITY; - tanar = readl(dev->base + TANAR); + readl(dev->base + TANAR); tbicr = readl(dev->base + TBICR); fullduplex = (cfg & CFG_DUPSTS) ? 1 : 0; -- cgit v1.2.3