diff options
author | Gao feng <gaofeng@cn.fujitsu.com> | 2013-12-10 09:37:32 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-12-11 20:21:26 +0100 |
commit | 79d4a94fab0a9cc1b55db45a98277a68ff1febd8 (patch) | |
tree | 64d527eae62f7d9e6fff5afc784da1942086cdd3 /drivers/net/vxlan.c | |
parent | bgmac: replace some magic values with defines (diff) | |
download | linux-79d4a94fab0a9cc1b55db45a98277a68ff1febd8.tar.xz linux-79d4a94fab0a9cc1b55db45a98277a68ff1febd8.zip |
vxlan: remove vxlan_group_used in vxlan_open
In vxlan_open, vxlan_group_used always returns true,
because the state of the vxlan deivces which we want
to open has alreay been running. and it has already
in vxlan_list.
Since ip_mc_join_group takes care of the reference
of struct ip_mc_list. removing vxlan_group_used here
is safe.
Signed-off-by: Gao feng <gaofeng@cn.fujitsu.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/vxlan.c')
-rw-r--r-- | drivers/net/vxlan.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/net/vxlan.c b/drivers/net/vxlan.c index 0358c07f7669..43dc9ee4758f 100644 --- a/drivers/net/vxlan.c +++ b/drivers/net/vxlan.c @@ -1935,7 +1935,6 @@ static void vxlan_uninit(struct net_device *dev) /* Start ageing timer and join group when device is brought up */ static int vxlan_open(struct net_device *dev) { - struct vxlan_net *vn = net_generic(dev_net(dev), vxlan_net_id); struct vxlan_dev *vxlan = netdev_priv(dev); struct vxlan_sock *vs = vxlan->vn_sock; @@ -1943,8 +1942,7 @@ static int vxlan_open(struct net_device *dev) if (!vs) return -ENOTCONN; - if (vxlan_addr_multicast(&vxlan->default_dst.remote_ip) && - vxlan_group_used(vn, &vxlan->default_dst.remote_ip)) { + if (vxlan_addr_multicast(&vxlan->default_dst.remote_ip)) { vxlan_sock_hold(vs); dev_hold(dev); queue_work(vxlan_wq, &vxlan->igmp_join); |