diff options
author | Minghao Chi <chi.minghao@zte.com.cn> | 2022-01-12 11:06:29 +0300 |
---|---|---|
committer | Marc Kleine-Budde <mkl@pengutronix.de> | 2022-02-24 10:26:04 +0300 |
commit | 51ae468aa7e412315203d13ef387751f0c58c55c (patch) | |
tree | b02a8ea1aa050b6d841f44427b27c73ba6fecfb4 | |
parent | 8d0a82e1f42f4c2531552a5d140ee119ecc253b6 (diff) | |
download | linux-51ae468aa7e412315203d13ef387751f0c58c55c.tar.xz |
can: softing: softing_netdev_open(): remove redundant ret variable
Return value from softing_startstop() directly instead of taking this
in another redundant variable.
Link: https://lore.kernel.org/all/20220112080629.667191-1-chi.minghao@zte.com.cn
Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: Minghao Chi <chi.minghao@zte.com.cn>
Signed-off-by: CGEL ZTE <cgel.zte@gmail.com>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
-rw-r--r-- | drivers/net/can/softing/softing_main.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/net/can/softing/softing_main.c b/drivers/net/can/softing/softing_main.c index d74e895bddf7..8d27ac66ca7f 100644 --- a/drivers/net/can/softing/softing_main.c +++ b/drivers/net/can/softing/softing_main.c @@ -392,13 +392,10 @@ static int softing_netdev_open(struct net_device *ndev) static int softing_netdev_stop(struct net_device *ndev) { - int ret; - netif_stop_queue(ndev); /* softing cycle does close_candev() */ - ret = softing_startstop(ndev, 0); - return ret; + return softing_startstop(ndev, 0); } static int softing_candev_set_mode(struct net_device *ndev, enum can_mode mode) |