• C
    slab: Simplify bootstrap · 3c583465
    Christoph Lameter 提交于
    The nodelists field in kmem_cache is pointing to the first unused
    object in the array field when bootstrap is complete.
    
    A problem with the current approach is that the statically sized
    kmem_cache structure use on boot can only contain NR_CPUS entries.
    If the number of nodes plus the number of cpus is greater then we
    would overwrite memory following the kmem_cache_boot definition.
    
    Increase the size of the array field to ensure that also the node
    pointers fit into the array field.
    
    Once we do that we no longer need the kmem_cache_nodelists
    array and we can then also use that structure elsewhere.
    Acked-by: NGlauber Costa <glommer@parallels.com>
    Signed-off-by: NChristoph Lameter <cl@linux.com>
    Signed-off-by: NPekka Enberg <penberg@kernel.org>
    3c583465
slab_def.h 5.0 KB