ipv6: Add rt6_get_cookie() function
authorMartin KaFai Lau <kafai@fb.com>
Sat, 23 May 2015 03:56:01 +0000 (20:56 -0700)
committerBen Hutchings <ben@decadent.org.uk>
Sat, 11 Nov 2017 13:34:32 +0000 (13:34 +0000)
commit22d2b8ef67c6f31540bf8bf141bba5adca231009
tree8b72a5db95b38bcf4590c26a155a3697f0a49b8a
parentabf387aec55213809ce53091979dbb383b150085
ipv6: Add rt6_get_cookie() function

commit b197df4f0f3782782e9ea8996e91b65ae33e8dd9 upstream.

Instead of doing the rt6->rt6i_node check whenever we need
to get the route's cookie.  Refactor it into rt6_get_cookie().
It is a prep work to handle FLOWI_FLAG_KNOWN_NH and also
percpu rt6_info later.

Signed-off-by: Martin KaFai Lau <kafai@fb.com>
Cc: Hannes Frederic Sowa <hannes@stressinduktion.org>
Cc: Steffen Klassert <steffen.klassert@secunet.com>
Cc: Julian Anastasov <ja@ssi.bg>
Signed-off-by: David S. Miller <davem@davemloft.net>
[bwh: Backported to 3.2:
 - Drop changes in inet6_sk_rx_dst_set(), sctp_v6_get_dst()
 - Adjust context]
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
include/net/ip6_fib.h
include/net/ip6_route.h
net/ipv6/ip6_tunnel.c
net/ipv6/xfrm6_policy.c
net/netfilter/ipvs/ip_vs_xmit.c