diff options
Diffstat (limited to 'drivers/net/vxlan.c')
-rw-r--r-- | drivers/net/vxlan.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/net/vxlan.c b/drivers/net/vxlan.c index f10e58ac9c1b..7cee7a3068ec 100644 --- a/drivers/net/vxlan.c +++ b/drivers/net/vxlan.c | |||
@@ -961,6 +961,8 @@ static netdev_tx_t vxlan_xmit(struct sk_buff *skb, struct net_device *dev) | |||
961 | iph->ttl = ttl ? : ip4_dst_hoplimit(&rt->dst); | 961 | iph->ttl = ttl ? : ip4_dst_hoplimit(&rt->dst); |
962 | tunnel_ip_select_ident(skb, old_iph, &rt->dst); | 962 | tunnel_ip_select_ident(skb, old_iph, &rt->dst); |
963 | 963 | ||
964 | nf_reset(skb); | ||
965 | |||
964 | vxlan_set_owner(dev, skb); | 966 | vxlan_set_owner(dev, skb); |
965 | 967 | ||
966 | /* See iptunnel_xmit() */ | 968 | /* See iptunnel_xmit() */ |
@@ -1504,6 +1506,14 @@ static __net_init int vxlan_init_net(struct net *net) | |||
1504 | static __net_exit void vxlan_exit_net(struct net *net) | 1506 | static __net_exit void vxlan_exit_net(struct net *net) |
1505 | { | 1507 | { |
1506 | struct vxlan_net *vn = net_generic(net, vxlan_net_id); | 1508 | struct vxlan_net *vn = net_generic(net, vxlan_net_id); |
1509 | struct vxlan_dev *vxlan; | ||
1510 | unsigned h; | ||
1511 | |||
1512 | rtnl_lock(); | ||
1513 | for (h = 0; h < VNI_HASH_SIZE; ++h) | ||
1514 | hlist_for_each_entry(vxlan, &vn->vni_list[h], hlist) | ||
1515 | dev_close(vxlan->dev); | ||
1516 | rtnl_unlock(); | ||
1507 | 1517 | ||
1508 | if (vn->sock) { | 1518 | if (vn->sock) { |
1509 | sk_release_kernel(vn->sock->sk); | 1519 | sk_release_kernel(vn->sock->sk); |