Skip to content

Commit ce3db6a

Browse files
Govindarajulu Varadarajandavem330
authored andcommitted
enic: drop IP proto check for vxlan tunnel delete
Commit d117909 ("enic: Add vxlan offload support for IPv6 pkts") added vxlan offload support for IPv6 pkts. Required change in enic_udp_tunnel_del was not made. This creates a bug where once user adds IPv6 tunnel, hw offload for that cannot be deleted. This patch removes check for IP proto in tunnel delete path. Driver need not check for IP proto since same UDP port cannot be used to create two tunnels. Fixes: d117909 ("enic: Add vxlan offload support for IPv6 pkts") Signed-off-by: Govindarajulu Varadarajan <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 650b4ec commit ce3db6a

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

drivers/net/ethernet/cisco/enic/enic_main.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -251,9 +251,8 @@ static void enic_udp_tunnel_del(struct net_device *netdev,
251251

252252
spin_lock_bh(&enic->devcmd_lock);
253253

254-
if ((ti->sa_family != AF_INET) ||
255-
((ntohs(ti->port) != enic->vxlan.vxlan_udp_port_number)) ||
256-
(ti->type != UDP_TUNNEL_TYPE_VXLAN)) {
254+
if ((ntohs(ti->port) != enic->vxlan.vxlan_udp_port_number) ||
255+
ti->type != UDP_TUNNEL_TYPE_VXLAN) {
257256
netdev_info(netdev, "udp_tnl: port:%d, sa_family: %d, type: %d not offloaded",
258257
ntohs(ti->port), ti->sa_family, ti->type);
259258
goto unlock;

0 commit comments

Comments
 (0)