[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1564563226-13367-1-git-send-email-dingxiang@cmss.chinamobile.com>
Date: Wed, 31 Jul 2019 16:53:46 +0800
From: Ding Xiang <dingxiang@...s.chinamobile.com>
To: christopher.lee@...i.com, davem@...emloft.net
Cc: netdev@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: [PATCH] myri10ge: remove unneeded variable
"error" is unneeded,just return 0
Signed-off-by: Ding Xiang <dingxiang@...s.chinamobile.com>
---
drivers/net/ethernet/myricom/myri10ge/myri10ge.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/net/ethernet/myricom/myri10ge/myri10ge.c b/drivers/net/ethernet/myricom/myri10ge/myri10ge.c
index d8b7fba..a4165e1 100644
--- a/drivers/net/ethernet/myricom/myri10ge/myri10ge.c
+++ b/drivers/net/ethernet/myricom/myri10ge/myri10ge.c
@@ -3037,7 +3037,6 @@ static int myri10ge_set_mac_address(struct net_device *dev, void *addr)
static int myri10ge_change_mtu(struct net_device *dev, int new_mtu)
{
struct myri10ge_priv *mgp = netdev_priv(dev);
- int error = 0;
netdev_info(dev, "changing mtu from %d to %d\n", dev->mtu, new_mtu);
if (mgp->running) {
@@ -3049,7 +3048,7 @@ static int myri10ge_change_mtu(struct net_device *dev, int new_mtu)
} else
dev->mtu = new_mtu;
- return error;
+ return 0;
}
/*
--
1.9.1
Powered by blists - more mailing lists