aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorSebastian Andrzej Siewior <bigeasy@linutronix.de>2010-04-04 16:19:01 -0400
committerKumar Gala <galak@kernel.crashing.org>2010-05-24 15:00:53 -0400
commit2289d2d1a8574a11e66b00c5a59090c6fc227751 (patch)
treefe4029daf1b04922b6f058a74a11240f0b9fca0e /arch
parent0472fd0755fed200c750ba57e5ea46f941914adb (diff)
powerpc/fsl-booke: fix the case where we are not in the first page
During boot we change the mapping a few times until we have a "defined" mapping. During this procedure a small 4KiB mapping is created and after that one a 64MiB. Currently the offset of the 4KiB page in that we run is zero because the complete startup up code is in first page which starts at RPN zero. If the code is recycled and moved to another location then its execution will fail because the start address in 64 MiB mapping is computed wrongly. It does not consider the offset to the page from the begin of the memory. This patch fixes this. Usually (system boot) r25 is zero so this does not change anything unless the code is recycled. Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'arch')
-rw-r--r--arch/powerpc/kernel/head_fsl_booke.S1
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/powerpc/kernel/head_fsl_booke.S b/arch/powerpc/kernel/head_fsl_booke.S
index edd4a57fd29e..36ee1db5fc47 100644
--- a/arch/powerpc/kernel/head_fsl_booke.S
+++ b/arch/powerpc/kernel/head_fsl_booke.S
@@ -275,6 +275,7 @@ skpinv: addi r6,r6,1 /* Increment */
2751: mflr r9 2751: mflr r9
276 rlwimi r6,r9,0,20,31 276 rlwimi r6,r9,0,20,31
277 addi r6,r6,(2f - 1b) 277 addi r6,r6,(2f - 1b)
278 add r6, r6, r25
278 mtspr SPRN_SRR0,r6 279 mtspr SPRN_SRR0,r6
279 mtspr SPRN_SRR1,r7 280 mtspr SPRN_SRR1,r7
280 rfi /* start execution out of TLB1[0] entry */ 281 rfi /* start execution out of TLB1[0] entry */