diff options
Diffstat (limited to 'net/ipv6/addrconf.c')
-rw-r--r-- | net/ipv6/addrconf.c | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c index c1e124bc8e1e..a7bcc0ab5e99 100644 --- a/net/ipv6/addrconf.c +++ b/net/ipv6/addrconf.c | |||
@@ -3386,9 +3386,15 @@ static int addrconf_notify(struct notifier_block *this, unsigned long event, | |||
3386 | } | 3386 | } |
3387 | 3387 | ||
3388 | if (idev) { | 3388 | if (idev) { |
3389 | if (idev->if_flags & IF_READY) | 3389 | if (idev->if_flags & IF_READY) { |
3390 | /* device is already configured. */ | 3390 | /* device is already configured - |
3391 | * but resend MLD reports, we might | ||
3392 | * have roamed and need to update | ||
3393 | * multicast snooping switches | ||
3394 | */ | ||
3395 | ipv6_mc_up(idev); | ||
3391 | break; | 3396 | break; |
3397 | } | ||
3392 | idev->if_flags |= IF_READY; | 3398 | idev->if_flags |= IF_READY; |
3393 | } | 3399 | } |
3394 | 3400 | ||
@@ -4009,6 +4015,12 @@ static void addrconf_dad_completed(struct inet6_ifaddr *ifp, bool bump_id) | |||
4009 | 4015 | ||
4010 | if (bump_id) | 4016 | if (bump_id) |
4011 | rt_genid_bump_ipv6(dev_net(dev)); | 4017 | rt_genid_bump_ipv6(dev_net(dev)); |
4018 | |||
4019 | /* Make sure that a new temporary address will be created | ||
4020 | * before this temporary address becomes deprecated. | ||
4021 | */ | ||
4022 | if (ifp->flags & IFA_F_TEMPORARY) | ||
4023 | addrconf_verify_rtnl(); | ||
4012 | } | 4024 | } |
4013 | 4025 | ||
4014 | static void addrconf_dad_run(struct inet6_dev *idev) | 4026 | static void addrconf_dad_run(struct inet6_dev *idev) |
@@ -5540,8 +5552,7 @@ static void addrconf_disable_change(struct net *net, __s32 newf) | |||
5540 | struct net_device *dev; | 5552 | struct net_device *dev; |
5541 | struct inet6_dev *idev; | 5553 | struct inet6_dev *idev; |
5542 | 5554 | ||
5543 | rcu_read_lock(); | 5555 | for_each_netdev(net, dev) { |
5544 | for_each_netdev_rcu(net, dev) { | ||
5545 | idev = __in6_dev_get(dev); | 5556 | idev = __in6_dev_get(dev); |
5546 | if (idev) { | 5557 | if (idev) { |
5547 | int changed = (!idev->cnf.disable_ipv6) ^ (!newf); | 5558 | int changed = (!idev->cnf.disable_ipv6) ^ (!newf); |
@@ -5550,7 +5561,6 @@ static void addrconf_disable_change(struct net *net, __s32 newf) | |||
5550 | dev_disable_change(idev); | 5561 | dev_disable_change(idev); |
5551 | } | 5562 | } |
5552 | } | 5563 | } |
5553 | rcu_read_unlock(); | ||
5554 | } | 5564 | } |
5555 | 5565 | ||
5556 | static int addrconf_disable_ipv6(struct ctl_table *table, int *p, int newf) | 5566 | static int addrconf_disable_ipv6(struct ctl_table *table, int *p, int newf) |