]> git.baikalelectronics.ru Git - kernel.git/commit
SLAB: don't allocate empty shared caches
authorEric Dumazet <dada1@cosmosbay.com>
Sun, 6 May 2007 21:49:28 +0000 (14:49 -0700)
committerLinus Torvalds <torvalds@woody.linux-foundation.org>
Mon, 7 May 2007 19:12:53 +0000 (12:12 -0700)
commit85a18500ebc2316453dcab5d3b45af11e2036b6a
tree9579700c6b8b99e873462018cf536c00ab76dfb6
parent8a5f87ac729dce4481bd4f8e47effede70a462b7
SLAB: don't allocate empty shared caches

We can avoid allocating empty shared caches and avoid unecessary check of
cache->limit.  We save some memory.  We avoid bringing into CPU cache
unecessary cache lines.

All accesses to l3->shared are already checking NULL pointers so this patch is
safe.

Signed-off-by: Eric Dumazet <dada1@cosmosbay.com>
Acked-by: Pekka Enberg <penberg@cs.helsinki.fi>
Cc: Christoph Lameter <clameter@engr.sgi.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
mm/slab.c