slub: Use the objsize from the kmem_cache_cpu structure

No need to access the kmem_cache structure. We have the same value
in kmem_cache_cpu.

Reviewed-by: Pekka Enberg <penberg@cs.helsinki.fi>
Signed-off-by: Christoph Lameter <clameter@sgi.com>
This commit is contained in:
Christoph Lameter 2008-02-15 23:45:25 -08:00
parent d692ef6dcd
commit 27d9e4e948
1 changed files with 1 additions and 1 deletions

View File

@ -1681,8 +1681,8 @@ static __always_inline void slab_free(struct kmem_cache *s,
unsigned long flags;
local_irq_save(flags);
debug_check_no_locks_freed(object, s->objsize);
c = get_cpu_slab(s, smp_processor_id());
debug_check_no_locks_freed(object, c->objsize);
if (likely(page == c->page && c->node >= 0)) {
object[c->offset] = c->freelist;
c->freelist = object;