]> git.baikalelectronics.ru Git - kernel.git/commit
neigh: Keep neighbour cache entries if number of them is small enough.
authorYOSHIFUJI Hideaki / 吉藤英明 <yoshfuji@linux-ipv6.org>
Tue, 22 Jan 2013 05:20:05 +0000 (05:20 +0000)
committerDavid S. Miller <davem@davemloft.net>
Tue, 22 Jan 2013 19:25:28 +0000 (14:25 -0500)
commitbc4e52919b1cad5ee3fc4498d59bfb28aabe3386
treedee52affa20715488fd361c370a4fc70ce05591c
parentab2457618377ef7f4935561214d2002ae0ffb2e4
neigh: Keep neighbour cache entries if number of them is small enough.

Since we have removed NCE (Neighbour Cache Entry) reference from
routing entries, the only refcnt holders of an NCE are its timer
(if running) and its owner table, in usual cases.  As a result,
neigh_periodic_work() purges NCEs over and over again even for
gateways.

It does not make sense to purge entries, if number of them is
very small, so keep them.  The minimum number of entries to keep
is specified by gc_thresh1.

Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Documentation/networking/ip-sysctl.txt
net/core/neighbour.c