]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
[PATCH] ppc64 boot: print firmware provided stackpointer
authorOlaf Hering <olh@suse.de>
Sat, 29 Oct 2005 00:46:50 +0000 (17:46 -0700)
committerPaul Mackerras <paulus@samba.org>
Sat, 29 Oct 2005 05:11:35 +0000 (15:11 +1000)
Show firmware provided stackpointer during boot.

This helps to find the "taboo" areas on the various boards.  claim tends to
fail for these memory areas, but some jokers return success anyway.

Use %p to print the load address, its a pointer.

Signed-off-by: Olaf Hering <olh@suse.de>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Anton Blanchard <anton@samba.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
arch/ppc64/boot/crt0.S
arch/ppc64/boot/main.c

index 8bfdeaf3be83fb7cbb8714c8653c4e67e397457a..9cc442263939750c94b8d55c96cea067668fa9c5 100644 (file)
@@ -54,5 +54,6 @@ clear_caches:
        sync
        isync
 
+       mr      r6,r1
        b       start
 
index 3304ed34c44b0ba61e4896d235027da26b565461..c1dc876bccab04d424ec7e0b9527c81b0f203462 100644 (file)
@@ -131,7 +131,7 @@ static unsigned long try_claim(unsigned long size)
        return addr;
 }
 
-void start(unsigned long a1, unsigned long a2, void *promptr)
+void start(unsigned long a1, unsigned long a2, void *promptr, void *sp)
 {
        unsigned long i;
        int len;
@@ -151,7 +151,7 @@ void start(unsigned long a1, unsigned long a2, void *promptr)
        if (getprop(chosen_handle, "stdin", &stdin, sizeof(stdin)) != 4)
                exit();
 
-       printf("\n\rzImage starting: loaded at 0x%lx\n\r", (unsigned long) _start);
+       printf("\n\rzImage starting: loaded at 0x%p (sp: 0x%p)\n\r", _start, sp);
 
        /*
         * The first available claim_base must be above the end of the