]> git.karo-electronics.de Git - linux-beck.git/commitdiff
sh: Fix address to decompress at when CONFIG_32BIT=y
authorMatt Fleming <matt@console-pimps.org>
Sat, 24 Apr 2010 12:28:20 +0000 (13:28 +0100)
committerMatt Fleming <matt@console-pimps.org>
Sun, 25 Apr 2010 19:44:23 +0000 (20:44 +0100)
When running in 32BIT mode the P1SEG region doesn't necessarily provide
a window onto RAM (it depends how the bootloader setup the PMB). The
correct location to place the decompressed kernel is the physical
address of _text.

Signed-off-by: Matt Fleming <matt@console-pimps.org>
arch/sh/boot/compressed/head_32.S

index 02a30935f0b90b61fecf22da0733a046d985d806..200c1d4f1efe4c518a6470993603d748550d4eae 100644 (file)
@@ -97,7 +97,11 @@ init_stack_addr:
 decompress_kernel_addr:
        .long   decompress_kernel
 kernel_start_addr:
+#ifdef CONFIG_32BIT
+       .long   ___pa(_text+PAGE_SIZE)
+#else
        .long   _text+PAGE_SIZE
+#endif
 
        .align  9
 fake_headers_as_bzImage: