diff options
author | Guo Zhengkui <guozhengkui@vivo.com> | 2022-03-08 21:43:09 +0800 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2022-03-09 19:40:36 -0800 |
commit | e58bc864630f0eb5e7bff8ac3c2d5816591189de (patch) | |
tree | 36d2e0b847f51867cf66f0a0be1171839aee759c /drivers/net/vxlan | |
parent | 24055bb87977e0c687b54ebf7bac8715f3636bc3 (diff) |
drivers: vxlan: fix returnvar.cocci warning
Fix the following coccicheck warning:
drivers/net/vxlan/vxlan_core.c:2995:5-8:
Unneeded variable: "ret". Return "0" on line 3004.
Fixes: f9c4bb0b245c ("vxlan: vni filtering support on collect metadata device")
Signed-off-by: Guo Zhengkui <guozhengkui@vivo.com>
Acked-by: Roopa Prabhu <roopa@nvidia.com>
Link: https://lore.kernel.org/r/20220308134321.29862-1-guozhengkui@vivo.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/vxlan')
-rw-r--r-- | drivers/net/vxlan/vxlan_core.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/vxlan/vxlan_core.c b/drivers/net/vxlan/vxlan_core.c index e440cdd4f710..3872f76ea1d3 100644 --- a/drivers/net/vxlan/vxlan_core.c +++ b/drivers/net/vxlan/vxlan_core.c @@ -2990,7 +2990,6 @@ static void vxlan_flush(struct vxlan_dev *vxlan, bool do_all) static int vxlan_stop(struct net_device *dev) { struct vxlan_dev *vxlan = netdev_priv(dev); - int ret = 0; vxlan_multicast_leave(vxlan); @@ -2999,7 +2998,7 @@ static int vxlan_stop(struct net_device *dev) vxlan_flush(vxlan, false); vxlan_sock_release(vxlan); - return ret; + return 0; } /* Stub, nothing needs to be done. */ |