net/ipv6: separate handling of FIB entries from dst based routes
Last step before flipping the data type for FIB entries: - use fib6_info_alloc to create FIB entries in ip6_route_info_create and addrconf_dst_alloc - use fib6_info_release in place of dst_release, ip6_rt_put and rt6_release - remove the dst_hold before calling __ip6_ins_rt or ip6_del_rt - when purging routes, drop per-cpu routes - replace inc and dec of rt6i_ref with fib6_info_hold and fib6_info_release - use rt->from since it points to the FIB entry - drop references to exception bucket, fib6_metrics and per-cpu from dst entries (those are relevant for fib entries only) Signed-off-by: David Ahern <dsahern@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
a64efe142f
commit
93531c6743
@@ -1283,7 +1283,7 @@ static void ndisc_router_discovery(struct sk_buff *skb)
|
||||
ND_PRINTK(0, err,
|
||||
"RA: %s got default router without neighbour\n",
|
||||
__func__);
|
||||
ip6_rt_put(rt);
|
||||
fib6_info_release(rt);
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -1313,7 +1313,7 @@ static void ndisc_router_discovery(struct sk_buff *skb)
|
||||
ND_PRINTK(0, err,
|
||||
"RA: %s got default router without neighbour\n",
|
||||
__func__);
|
||||
ip6_rt_put(rt);
|
||||
fib6_info_release(rt);
|
||||
return;
|
||||
}
|
||||
neigh->flags |= NTF_ROUTER;
|
||||
@@ -1499,7 +1499,7 @@ skip_routeinfo:
|
||||
ND_PRINTK(2, warn, "RA: invalid RA options\n");
|
||||
}
|
||||
out:
|
||||
ip6_rt_put(rt);
|
||||
fib6_info_release(rt);
|
||||
if (neigh)
|
||||
neigh_release(neigh);
|
||||
}
|
||||
|
Reference in New Issue
Block a user