diff options
author | Zheng Yongjun <zhengyongjun3@huawei.com> | 2020-12-09 17:17:51 +0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-12-09 17:05:36 -0800 |
commit | 05372c456f2dceff55faa57280d4ae534028c827 (patch) | |
tree | ff81d13841bd614cb771bfe30cb699e5c240f3f4 /drivers | |
parent | e3bc6566b88613dc3ee13fb74727d58826ca5132 (diff) | |
download | linux-stable-05372c456f2dceff55faa57280d4ae534028c827.tar.gz linux-stable-05372c456f2dceff55faa57280d4ae534028c827.tar.bz2 linux-stable-05372c456f2dceff55faa57280d4ae534028c827.zip |
net: marvell: prestera: simplify the return expression of prestera_port_close()
Simplify the return expression.
Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/ethernet/marvell/prestera/prestera_main.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/drivers/net/ethernet/marvell/prestera/prestera_main.c b/drivers/net/ethernet/marvell/prestera/prestera_main.c index 0f20e0788cce..13bd58dafc6c 100644 --- a/drivers/net/ethernet/marvell/prestera/prestera_main.c +++ b/drivers/net/ethernet/marvell/prestera/prestera_main.c @@ -93,15 +93,10 @@ static int prestera_port_open(struct net_device *dev) static int prestera_port_close(struct net_device *dev) { struct prestera_port *port = netdev_priv(dev); - int err; netif_stop_queue(dev); - err = prestera_hw_port_state_set(port, false); - if (err) - return err; - - return 0; + return prestera_hw_port_state_set(port, false); } static netdev_tx_t prestera_port_xmit(struct sk_buff *skb, |