From: Pekka J Enberg Subject: slub: look up object from the freelist once We only need to look up object from c->page->freelist once in __slab_alloc(). Signed-off-by: Pekka Enberg Signed-off-by: Christoph Lameter --- mm/slub.c | 2 -- 1 file changed, 2 deletions(-) Index: linux-2.6/mm/slub.c =================================================================== --- linux-2.6.orig/mm/slub.c 2008-02-29 11:44:52.153297103 -0800 +++ linux-2.6/mm/slub.c 2008-02-29 11:45:00.681345009 -0800 @@ -1486,7 +1486,6 @@ load_freelist: if (unlikely(SlabDebug(c->page))) goto debug; - object = c->page->freelist; c->freelist = object[c->offset]; c->page->inuse = s->objects; c->page->freelist = NULL; @@ -1542,7 +1541,6 @@ new_slab: return NULL; debug: - object = c->page->freelist; if (!alloc_debug_processing(s, c->page, object, addr)) goto another_slab;