From ed52a8af5cd1935b95b3adc4e5e36e8f1334c958 Mon Sep 17 00:00:00 2001 From: Aaron Lindsay Date: Mon, 17 Dec 2012 00:36:25 -0500 Subject: [PATCH] arch/arm: Fixup formatting to match arch/i386 --- arch/arm/kernel.ld | 16 ++++++++++++---- arch/arm/start.S | 16 +++++++++------- 2 files changed, 21 insertions(+), 11 deletions(-) diff --git a/arch/arm/kernel.ld b/arch/arm/kernel.ld index 42f3f20..76a40ba 100644 --- a/arch/arm/kernel.ld +++ b/arch/arm/kernel.ld @@ -2,8 +2,11 @@ ENTRY (start) SECTIONS { - . = 0x80100000; - .text : { *(.text*) *(.rodata*) } + . = 0xc0100000; + kernel_start = .; + .text : { + *(.text*) *(.rodata*) + } .init : { early_initcalls_start = .; *(.earlyinitcalls*) @@ -12,8 +15,13 @@ SECTIONS *(.driversubsysinitcalls*) *(.deviceinitcalls*) initcalls_end = .; + *(.init*) + } + .data : { + *(.data*) + } + .bss : { + *(.bss*) *(COMMON*) } - .data : { *(.data*) } - .bss : { *(.bss*) *(COMMON*) } kernel_end = .; } diff --git a/arch/arm/start.S b/arch/arm/start.S index bade755..bd4e53c 100644 --- a/arch/arm/start.S +++ b/arch/arm/start.S @@ -18,6 +18,8 @@ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ +#define STACK_SIZE 0x4000 /* 16k */ + /* * Kernel entry in assembly. This handles relocating the kernel so that it is * in both physical and virtual memory where we want it to be. We copy the @@ -27,7 +29,7 @@ * function in C using the address it is linked against. When the MMU gets * initialized fully later, it will remove the initial 1:1 mapping. */ -.globl start +.global start start: str r1, machine_type /* Backup atags/machine type registers so we can access them later from C */ str r2, atags_ptr @@ -37,7 +39,7 @@ copy_kernel_lr: /* Used to calculate address at which kernel is currently loaded bl setup_mmu - ldr sp, =stack+0x10000 /* Set up the stack */ + ldr sp, =stack+STACK_SIZE /* Set up the stack */ bl main 1: @@ -174,17 +176,17 @@ tt_base_align: .word 0b111111111111111 /* 16k - 1 */ tt_section_align: .word 0b11111111111111111111 /* 1mb - 1 */ -.globl tt_base_virtual +.global tt_base_virtual tt_base_virtual: .word 0 -.globl tt_base_physical +.global tt_base_physical tt_base_physical: .word 0 -.globl atags_ptr +.global atags_ptr atags_ptr: .word 0 -.globl machine_type +.global machine_type machine_type: .word 0 -.comm stack, 0x10000 /* Reserve 64k for the stack in .bss */ +.lcomm stack, STACK_SIZE /* Reserve space for the stack in .bss */