From fd715fa95cc6bdd57f558cdbfc43bc768ec9645b Mon Sep 17 00:00:00 2001 From: Rafaël Carré Date: Fri, 18 Jun 2010 17:33:51 +0000 Subject: as3525*: enable MMU in bootloader Reserve 1MB of DRAM for loading rockbox and use the rest as BSS Write sdram setup in assembler and move it to a separate file, together with MMU init code git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26926 a1c6a512-1295-4272-9138-f99709370657 --- firmware/target/arm/as3525/boot.lds | 28 +++++++++------------------- 1 file changed, 9 insertions(+), 19 deletions(-) (limited to 'firmware/target/arm/as3525/boot.lds') diff --git a/firmware/target/arm/as3525/boot.lds b/firmware/target/arm/as3525/boot.lds index 502e90c22b..2274eea13a 100644 --- a/firmware/target/arm/as3525/boot.lds +++ b/firmware/target/arm/as3525/boot.lds @@ -6,39 +6,31 @@ OUTPUT_FORMAT(elf32-littlearm) OUTPUT_ARCH(arm) STARTUP(target/arm/crt0.o) -#ifdef SANSA_CLIPV2 -#define RAMORIG 0x0 /* DRAM */ -#define RAMSIZE (MEM*0x100000) -#else -#define RAMORIG 0x81000000 /* IRAM */ -#define RAMSIZE 0x50000 -#endif +#define LOAD_SIZE 0x100000 /* Reserve 1MB for loading the firmware */ MEMORY { - RAM : ORIGIN = RAMORIG, LENGTH = RAMSIZE + IRAM : ORIGIN = IRAM_ORIG, LENGTH = IRAM_SIZE + DRAM : ORIGIN = DRAM_ORIG + LOAD_SIZE, LENGTH = DRAM_SIZE - LOAD_SIZE - TTB_SIZE } SECTIONS { - . = RAMORIG; + . = IRAM_ORIG; .text : { *(.init.text) *(.glue_7) *(.glue_7t) *(.text*) - } > RAM + *(.icode) + } > IRAM .data : { - *(.icode) - *(.irodata) - *(.idata) *(.data*) - *(.ncdata*) *(.rodata*) _dataend = . ; - } > RAM + } > IRAM .stack (NOLOAD) : { @@ -48,14 +40,12 @@ SECTIONS . += 0x2000; _stackend = .; stackend = .; - } > RAM + } > IRAM .bss (NOLOAD) : { _edata = .; *(.bss*); - *(.ibss); *(COMMON) - *(.ncbss*); _end = .; - } > RAM + } > DRAM } -- cgit v1.2.3