diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2010-10-04 11:22:34 -0400 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2010-10-08 05:07:32 -0400 |
commit | a4ae41341fd39af6e25ec9861a6a4dc0c5c58b16 (patch) | |
tree | 1f36e414f8b3d29ddbe6d0407b0c141cb8d8b74d | |
parent | 5085f3ff458521045f7e43da62b8c30ea7df2e82 (diff) |
ARM: cleanup boot cpu calling __mmap_switched
This allows us to relocate __mmap_switched and associated data away
from the head section.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
-rw-r--r-- | arch/arm/kernel/head-common.S | 3 | ||||
-rw-r--r-- | arch/arm/kernel/head.S | 3 |
2 files changed, 3 insertions, 3 deletions
diff --git a/arch/arm/kernel/head-common.S b/arch/arm/kernel/head-common.S index 6ad24d2cb14b..9f473ef2a64c 100644 --- a/arch/arm/kernel/head-common.S +++ b/arch/arm/kernel/head-common.S | |||
@@ -18,7 +18,6 @@ | |||
18 | .align 2 | 18 | .align 2 |
19 | .type __switch_data, %object | 19 | .type __switch_data, %object |
20 | __switch_data: | 20 | __switch_data: |
21 | .long __mmap_switched | ||
22 | .long __data_loc @ r4 | 21 | .long __data_loc @ r4 |
23 | .long _data @ r5 | 22 | .long _data @ r5 |
24 | .long __bss_start @ r6 | 23 | .long __bss_start @ r6 |
@@ -39,7 +38,7 @@ __switch_data: | |||
39 | * r9 = processor ID | 38 | * r9 = processor ID |
40 | */ | 39 | */ |
41 | __mmap_switched: | 40 | __mmap_switched: |
42 | adr r3, __switch_data + 4 | 41 | adr r3, __switch_data |
43 | 42 | ||
44 | ldmia r3!, {r4, r5, r6, r7} | 43 | ldmia r3!, {r4, r5, r6, r7} |
45 | cmp r4, r5 @ Copy data segment if needed | 44 | cmp r4, r5 @ Copy data segment if needed |
diff --git a/arch/arm/kernel/head.S b/arch/arm/kernel/head.S index eb62bf947212..aa6ab9d86461 100644 --- a/arch/arm/kernel/head.S +++ b/arch/arm/kernel/head.S | |||
@@ -95,13 +95,14 @@ ENTRY(stext) | |||
95 | * above. On return, the CPU will be ready for the MMU to be | 95 | * above. On return, the CPU will be ready for the MMU to be |
96 | * turned on, and r0 will hold the CPU control register value. | 96 | * turned on, and r0 will hold the CPU control register value. |
97 | */ | 97 | */ |
98 | ldr r13, __switch_data @ address to jump to after | 98 | ldr r13, =__mmap_switched @ address to jump to after |
99 | @ mmu has been enabled | 99 | @ mmu has been enabled |
100 | adr lr, BSYM(__enable_mmu) @ return (PIC) address | 100 | adr lr, BSYM(__enable_mmu) @ return (PIC) address |
101 | ARM( add pc, r10, #PROCINFO_INITFUNC ) | 101 | ARM( add pc, r10, #PROCINFO_INITFUNC ) |
102 | THUMB( add r12, r10, #PROCINFO_INITFUNC ) | 102 | THUMB( add r12, r10, #PROCINFO_INITFUNC ) |
103 | THUMB( mov pc, r12 ) | 103 | THUMB( mov pc, r12 ) |
104 | ENDPROC(stext) | 104 | ENDPROC(stext) |
105 | .ltorg | ||
105 | 106 | ||
106 | #if defined(CONFIG_SMP) | 107 | #if defined(CONFIG_SMP) |
107 | ENTRY(secondary_startup) | 108 | ENTRY(secondary_startup) |