aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kernel/head_40x.S
diff options
context:
space:
mode:
authorScott Wood <scottwood@freescale.com>2011-07-25 07:29:33 -0400
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2011-09-19 19:19:47 -0400
commit6dece0eb69b2a28e18d104bc5d707f1cb673f5e0 (patch)
treea5f3fcffc289d71cb31152e7d07f14da49607643 /arch/powerpc/kernel/head_40x.S
parent6c493685f1b209dd4ae41eb52c818cf12da20def (diff)
powerpc/32: Pass device tree address as u64 to machine_init
u64 is used rather than phys_addr_t to keep things simple, as this is called from assembly code. Update callers to pass a 64-bit address in r3/r4. Other unused register assignments that were once parameters to machine_init are dropped. For FSL BookE, look up the physical address of the device tree from the effective address passed in r3 by the loader. This is required for situations where memory does not start at zero (due to AMP or IOMMU-less virtualization), and thus the IMA doesn't start at zero, and thus the device tree effective address does not equal the physical address. Signed-off-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/kernel/head_40x.S')
-rw-r--r--arch/powerpc/kernel/head_40x.S15
1 files changed, 3 insertions, 12 deletions
diff --git a/arch/powerpc/kernel/head_40x.S b/arch/powerpc/kernel/head_40x.S
index a91626d87fc9..872a6af83bad 100644
--- a/arch/powerpc/kernel/head_40x.S
+++ b/arch/powerpc/kernel/head_40x.S
@@ -58,13 +58,7 @@
58_ENTRY(_stext); 58_ENTRY(_stext);
59_ENTRY(_start); 59_ENTRY(_start);
60 60
61 /* Save parameters we are passed. 61 mr r31,r3 /* save device tree ptr */
62 */
63 mr r31,r3
64 mr r30,r4
65 mr r29,r5
66 mr r28,r6
67 mr r27,r7
68 62
69 /* We have to turn on the MMU right away so we get cache modes 63 /* We have to turn on the MMU right away so we get cache modes
70 * set correctly. 64 * set correctly.
@@ -849,11 +843,8 @@ start_here:
849/* 843/*
850 * Decide what sort of machine this is and initialize the MMU. 844 * Decide what sort of machine this is and initialize the MMU.
851 */ 845 */
852 mr r3,r31 846 li r3,0
853 mr r4,r30 847 mr r4,r31
854 mr r5,r29
855 mr r6,r28
856 mr r7,r27
857 bl machine_init 848 bl machine_init
858 bl MMU_init 849 bl MMU_init
859 850