sfc: cleanup a condition in efx_udp_tunnel_del()
Subsystems (4)
PATCH 1/1 sfc: cleanup a condition in efx_udp_tunnel_del()
Presumably if there is an "add" function, there is also a "del" function. But it causes a static checker warning because it looks like a common cut and paste bug.
Signed-off-by Dan Carpenter <[email protected]>
drivers/net/ethernet/sfc/efx.c +1 -1
@@ -2404,7 +2404,7 @@ static void efx_udp_tunnel_del(struct net_device *dev, struct udp_tunnel_info *t tnl.type = (u16 )efx_tunnel_type; tnl.port = ti->port; -if (efx->type->udp_tnl_add_port) +if (efx->type->udp_tnl_del_port) (void )efx->type->udp_tnl_del_port (efx, tnl); }
Quoted 5 lines · Dan Carpenter
Presumably if there is an "add" function, there is also a "del" function. But it causes a static checker warning because it looks like a common cut and paste bug.
Signed-off-by Dan Carpenter <[email protected]>
Agreed, looks like a cut-n-paste buglet.
Acked-by Jarod Wilson <[email protected]>
Signature · 2 lines
Jarod Wilson [email protected]
David Miller
maintainerFrom: Dan Carpenter <[email protected]>
Date: Wed, 22 Mar 2017 12:10:02 +0300
Quoted 5 lines
Presumably if there is an "add" function, there is also a "del" function. But it causes a static checker warning because it looks like a common cut and paste bug.
Signed-off-by Dan Carpenter <[email protected]>
Looks good, applied, thanks Dan.