diff options
Diffstat (limited to 'net/ipv4/ipmr.c')
-rw-r--r-- | net/ipv4/ipmr.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/net/ipv4/ipmr.c b/net/ipv4/ipmr.c index 9dbf5909f3a6..302b7eb507c9 100644 --- a/net/ipv4/ipmr.c +++ b/net/ipv4/ipmr.c | |||
@@ -149,7 +149,7 @@ struct net_device *ipmr_new_tunnel(struct vifctl *v) | |||
149 | if (err == 0 && (dev = __dev_get_by_name(p.name)) != NULL) { | 149 | if (err == 0 && (dev = __dev_get_by_name(p.name)) != NULL) { |
150 | dev->flags |= IFF_MULTICAST; | 150 | dev->flags |= IFF_MULTICAST; |
151 | 151 | ||
152 | in_dev = __in_dev_get(dev); | 152 | in_dev = __in_dev_get_rtnl(dev); |
153 | if (in_dev == NULL && (in_dev = inetdev_init(dev)) == NULL) | 153 | if (in_dev == NULL && (in_dev = inetdev_init(dev)) == NULL) |
154 | goto failure; | 154 | goto failure; |
155 | in_dev->cnf.rp_filter = 0; | 155 | in_dev->cnf.rp_filter = 0; |
@@ -278,7 +278,7 @@ static int vif_delete(int vifi) | |||
278 | 278 | ||
279 | dev_set_allmulti(dev, -1); | 279 | dev_set_allmulti(dev, -1); |
280 | 280 | ||
281 | if ((in_dev = __in_dev_get(dev)) != NULL) { | 281 | if ((in_dev = __in_dev_get_rtnl(dev)) != NULL) { |
282 | in_dev->cnf.mc_forwarding--; | 282 | in_dev->cnf.mc_forwarding--; |
283 | ip_rt_multicast_event(in_dev); | 283 | ip_rt_multicast_event(in_dev); |
284 | } | 284 | } |
@@ -421,7 +421,7 @@ static int vif_add(struct vifctl *vifc, int mrtsock) | |||
421 | return -EINVAL; | 421 | return -EINVAL; |
422 | } | 422 | } |
423 | 423 | ||
424 | if ((in_dev = __in_dev_get(dev)) == NULL) | 424 | if ((in_dev = __in_dev_get_rtnl(dev)) == NULL) |
425 | return -EADDRNOTAVAIL; | 425 | return -EADDRNOTAVAIL; |
426 | in_dev->cnf.mc_forwarding++; | 426 | in_dev->cnf.mc_forwarding++; |
427 | dev_set_allmulti(dev, +1); | 427 | dev_set_allmulti(dev, +1); |