On Wed, Dec 24, 2003 at 05:09:42AM -0800, William Lee Irwin III wrote: > ptecache refresh. Includes the shrink_slab() and smp_local_irq_* > suggestions as well as a fix for IPI recursion found while running > hackbench on -wli, moving the "don't shrink lowmem slabs if gfp_mask > wants highmem" logic into the shrinkers themselves, and converting > shrink_pagetable_cache() to use on_each_cpu(). > How's this look? This tries to adjust the reclaim logic so it returns status like other shrinkers attached both incrementally and as a whole-hog replacement. BTW delta = scanned * shrinker->seeks; delta *= (*shrinker->shrinker)(0, gfp_mask); do_div(delta, pages + 1); shrinker->nr += delta; if (shrinker->nr > SHRINK_BATCH) { long nr_to_scan = shrinker->nr; more aggressively reclaims slabs requiring _more_ seeks to refill. -- wli