• Robert Love's avatar
    [PATCH] mark 3 variables as __initdata · 602c7aa8
    Robert Love authored
    The attached patch marks the following variables with __initdata:
    
            arch/i386/kernel/mpparse.c :: static unsigned int num_processors
            arch/i386/kernel/smpboot.c :: static int smp_b_stepping
            arch/i386/kernel/smpboot.c :: static int max_cpus
    
    The data is static and only used by __init functions so can successfully
    be jettisoned after boot.  Compiled and booted successfully on an SMP
    machine.
    
    I also set max_cpus to NR_CPUS instead of -1.  Besides being the
    logically correct value and simplifying a loop elsewhere, this change
    allows NR_CPUS to be set to various values other than the normal 32
    which is growing in utility with the hotplug CPU changes now in
    mainline.
    602c7aa8
smpboot.c 30.3 KB