Subject: Very long list of struct dst_entry in dst_garbage_list

From: Eric Dumazet <[email-masked]>
Date: Fri, 05 May 2006 18:13:30 +0200

I noticed that after a 'ip route flush cache' (manual or timer 
triggered) on a busy server, XXXXX entries are added to dst_garbage_list.
(XXXXX depends on the number of established sockets)

Every 1/10th second (DST_GC_MIN) , net/core/dst.c::dst_run_gc() is 
fired, and try to free some entries from the list, but many entries have 
a non null refcnt and stay in the list for the next run.

Linux version is 2.6.17-rc3.

Do you think a rework of  dst_run_gc() function is necessary, (using a 
batch mode to limit the number of entries examined at each run), or is 
it a "should not happen, something is broken" situation ?

Eric