]> pilppa.com Git - linux-2.6-omap-h63xx.git/commit
[IPV4]: Convert rt_check_expire() from softirq processing to workqueue.
authorEric Dumazet <dada1@cosmosbay.com>
Sat, 15 Sep 2007 17:55:54 +0000 (10:55 -0700)
committerDavid S. Miller <davem@sunset.davemloft.net>
Wed, 10 Oct 2007 23:49:25 +0000 (16:49 -0700)
commit39c90ece7565f5c47110c2fa77409d7a9478bd5b
tree220bf734ed470024901226675550501d45192f0e
parentdac24ab396fc92985060d5cb3c467d2d0ffc0c20
[IPV4]: Convert rt_check_expire() from softirq processing to workqueue.

On loaded/big hosts, rt_check_expire() if of litle use, because it
generally breaks out of its main loop because of a jiffies change.

It can take a long time (read : timer invocations) to actually
scan the whole hash table, freeing unused entries.

Converting it to use a workqueue instead of softirq is a nice
move because we can allow rt_check_expire() to do the scan
it is supposed to do, without hogging the CPU.

This has an impact on the average number of entries in cache,
reducing ram usage. Cache is more responsive to parameter
changes (/proc/sys/net/ipv4/route/gc_timeout and
/proc/sys/net/ipv4/route/gc_interval)

Note: Maybe the default value of gc_interval (60 seconds)
is too high, since this means we actually need 5 (300/60)
invocations to scan the whole table.

Signed-off-by: Eric Dumazet <dada1@cosmosbay.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/route.c