From: stephen hemminger Date: Mon, 12 Apr 2010 05:41:31 +0000 (+0000) Subject: IPv6: keep route for tentative address X-Git-Tag: upstream/snapshot3+hdmi~14568^2~505 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=93fa159abe50d3c55c7f83622d3f5c09b6e06f4b;p=platform%2Fadaptation%2Frenesas_rcar%2Frenesas_kernel.git IPv6: keep route for tentative address Recent changes preserve IPv6 address when link goes down (good). But would cause address to point to dead dst entry (bad). The simplest fix is to just not delete route if address is being held for later use. Signed-off-by: Stephen Hemminger Signed-off-by: David S. Miller --- diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c index 1b00bfe..a9913d2 100644 --- a/net/ipv6/addrconf.c +++ b/net/ipv6/addrconf.c @@ -4047,7 +4047,8 @@ static void __ipv6_ifa_notify(int event, struct inet6_ifaddr *ifp) addrconf_leave_anycast(ifp); addrconf_leave_solict(ifp->idev, &ifp->addr); dst_hold(&ifp->rt->u.dst); - if (ip6_del_rt(ifp->rt)) + + if (ifp->dead && ip6_del_rt(ifp->rt)) dst_free(&ifp->rt->u.dst); break; }