]> git.baikalelectronics.ru Git - kernel.git/commit
net/ipv6: Add anycast addresses to a global hashtable
authorJeff Barnhill <0xeffeff@gmail.com>
Fri, 2 Nov 2018 20:23:57 +0000 (20:23 +0000)
committerDavid S. Miller <davem@davemloft.net>
Sat, 3 Nov 2018 06:54:56 +0000 (23:54 -0700)
commit3b18eb66e0c2d9668b030d33b6e913e265a2b726
treebfad5bc2bff6bc70d8455db794c7b779cc81e9f1
parentee11e84ca5afea1318e61613933cb68f509dcb11
net/ipv6: Add anycast addresses to a global hashtable

icmp6_send() function is expensive on systems with a large number of
interfaces. Every time it’s called, it has to verify that the source
address does not correspond to an existing anycast address by looping
through every device and every anycast address on the device.  This can
result in significant delays for a CPU when there are a large number of
neighbors and ND timers are frequently timing out and calling
neigh_invalidate().

Add anycast addresses to a global hashtable to allow quick searching for
matching anycast addresses.  This is based on inet6_addr_lst in addrconf.c.

Signed-off-by: Jeff Barnhill <0xeffeff@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/addrconf.h
include/net/if_inet6.h
net/ipv6/af_inet6.c
net/ipv6/anycast.c