• Andrew Morton's avatar
    [PATCH] slab: fix off-by-one in size calculation · 16d99651
    Andrew Morton authored
    From: Manfred Spraul <manfred@colorfullife.com>
    
    Brian spotted a stupid bug in the slab initialization:
    
    If multiple objects fit into one cacheline, then the allocator ignores
    SLAB_HWCACHE_ALIGN and squeezes the objects into the same cacheline.  The
    implementation contains an off by one error and thus doesn't work correctly:
    For Athlon optimized kernels, the 32-byte slab uses 64 byte of memory.
    16d99651
slab.c 64.3 KB