diff options
Diffstat (limited to 'net/ipv6')
-rw-r--r-- | net/ipv6/addrconf.c | 4 | ||||
-rw-r--r-- | net/ipv6/mcast.c | 1 | ||||
-rw-r--r-- | net/ipv6/route.c | 2 |
3 files changed, 5 insertions, 2 deletions
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c index c02280a4d126..6b8ebc5da0e1 100644 --- a/net/ipv6/addrconf.c +++ b/net/ipv6/addrconf.c | |||
@@ -434,6 +434,10 @@ static struct inet6_dev * ipv6_add_dev(struct net_device *dev) | |||
434 | /* Join all-node multicast group */ | 434 | /* Join all-node multicast group */ |
435 | ipv6_dev_mc_inc(dev, &in6addr_linklocal_allnodes); | 435 | ipv6_dev_mc_inc(dev, &in6addr_linklocal_allnodes); |
436 | 436 | ||
437 | /* Join all-router multicast group if forwarding is set */ | ||
438 | if (ndev->cnf.forwarding && dev && (dev->flags & IFF_MULTICAST)) | ||
439 | ipv6_dev_mc_inc(dev, &in6addr_linklocal_allrouters); | ||
440 | |||
437 | return ndev; | 441 | return ndev; |
438 | } | 442 | } |
439 | 443 | ||
diff --git a/net/ipv6/mcast.c b/net/ipv6/mcast.c index b853f06cc148..16c33e308121 100644 --- a/net/ipv6/mcast.c +++ b/net/ipv6/mcast.c | |||
@@ -257,7 +257,6 @@ static struct inet6_dev *ip6_mc_find_dev_rcu(struct net *net, | |||
257 | 257 | ||
258 | if (rt) { | 258 | if (rt) { |
259 | dev = rt->dst.dev; | 259 | dev = rt->dst.dev; |
260 | dev_hold(dev); | ||
261 | dst_release(&rt->dst); | 260 | dst_release(&rt->dst); |
262 | } | 261 | } |
263 | } else | 262 | } else |
diff --git a/net/ipv6/route.c b/net/ipv6/route.c index 8c2e3ab58f2a..22b766407de1 100644 --- a/net/ipv6/route.c +++ b/net/ipv6/route.c | |||
@@ -1077,7 +1077,7 @@ struct dst_entry *icmp6_dst_alloc(struct net_device *dev, | |||
1077 | struct net *net = dev_net(dev); | 1077 | struct net *net = dev_net(dev); |
1078 | 1078 | ||
1079 | if (unlikely(!idev)) | 1079 | if (unlikely(!idev)) |
1080 | return NULL; | 1080 | return ERR_PTR(-ENODEV); |
1081 | 1081 | ||
1082 | rt = ip6_dst_alloc(&net->ipv6.ip6_dst_ops, dev, 0); | 1082 | rt = ip6_dst_alloc(&net->ipv6.ip6_dst_ops, dev, 0); |
1083 | if (unlikely(!rt)) { | 1083 | if (unlikely(!rt)) { |