OSDN Git Service

ipv6: Move dst->from into struct rt6_info.
authorDavid Miller <davem@davemloft.net>
Tue, 28 Nov 2017 20:40:40 +0000 (15:40 -0500)
committerDavid S. Miller <davem@davemloft.net>
Thu, 30 Nov 2017 14:54:26 +0000 (09:54 -0500)
commit3a2232e92e87166a8a5113e918b8c7b7bdce4d83
treed4bea5d4b31fe38dde724e8eb102038438f17f36
parentb6ca8bd5a9198c70c48297390723e4e56bd6e879
ipv6: Move dst->from into struct rt6_info.

The dst->from value is only used by ipv6 routes to track where
a route "came from".

Any time we clone or copy a core ipv6 route in the ipv6 routing
tables, we have the copy/clone's ->from point to the base route.

This is used to handle route expiration properly.

Only ipv6 uses this mechanism, and only ipv6 code references
it.  So it is safe to move it into rt6_info.

Signed-off-by: David S. Miller <davem@davemloft.net>
Reviewed-by: Eric Dumazet <edumazet@google.com>
include/net/dst.h
include/net/ip6_fib.h
net/core/dst.c
net/ipv6/route.c