[POWERPC] 32-bit early_init() should zero from __bss_start to __bss_stop only
authorMark A. Greer <mgreer@mvista.com>
Wed, 25 Oct 2006 23:36:49 +0000 (16:36 -0700)
committerPaul Mackerras <paulus@samba.org>
Fri, 16 Mar 2007 05:38:19 +0000 (16:38 +1100)
Currently, early_init() in setup_32.c zeroes from '_bss_start' to '_end'.
It should only zero from '__bss_start' to '__bss_stop'.  This patch does that.

Signed-off-by: Mark A. Greer <mgreer@mvista.com>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
arch/powerpc/kernel/setup_32.c

index 44a6a3c47feb5a4f666be6ba4a0c402ffbe74526..f688548f74cd7e0f8a2b2938e7386e2581dfbec0 100644 (file)
@@ -92,7 +92,8 @@ unsigned long __init early_init(unsigned long dt_ptr)
 
        /* First zero the BSS -- use memset_io, some platforms don't have
         * caches on yet */
-       memset_io((void __iomem *)PTRRELOC(&__bss_start), 0, _end - __bss_start);
+       memset_io((void __iomem *)PTRRELOC(&__bss_start), 0,
+                       __bss_stop - __bss_start);
 
        /*
         * Identify the CPU type and fix up code sections