diff options
author | Maurus Cuelenaere <mcuelenaere@gmail.com> | 2009-06-18 18:16:15 +0000 |
---|---|---|
committer | Maurus Cuelenaere <mcuelenaere@gmail.com> | 2009-06-18 18:16:15 +0000 |
commit | 2fb6396f5a73e52d059f8472a8dceba59ce31250 (patch) | |
tree | 5f0da6964bc5f4582b88d2f16a3d2eb8626ee628 /firmware | |
parent | 0181bc42c942797b1e215e6f7861aa760207b8db (diff) |
Ingenic Jz4740: enable IRAM (only core, without ibss)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21331 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware')
-rw-r--r-- | firmware/export/config.h | 5 | ||||
-rw-r--r-- | firmware/target/mips/ingenic_jz47xx/app.lds | 32 | ||||
-rw-r--r-- | firmware/target/mips/ingenic_jz47xx/crt0.S | 12 |
3 files changed, 15 insertions, 34 deletions
diff --git a/firmware/export/config.h b/firmware/export/config.h index 696c923bb6..e53e19ac1d 100644 --- a/firmware/export/config.h +++ b/firmware/export/config.h @@ -639,13 +639,14 @@ Lyre prototype 1*/ (CONFIG_CPU == AS3525 && MEMORYSIZE > 2) || /* AS3525 +2MB: core, plugins, codecs */ \ (CONFIG_CPU == AS3525 && MEMORYSIZE <= 2 && !defined(PLUGIN) && !defined(CODEC)) || /* AS3525 2MB:core only */ \ (CONFIG_CPU == PNX0101) || \ - (CONFIG_CPU == S5L8700)) /* Samsung S5L8700: core, plugins, codecs */ + (CONFIG_CPU == S5L8700)) /* Samsung S5L8700: core, plugins, codecs */ || \ + (CONFIG_CPU == JZ4732 && !defined(PLUGIN) && !defined(CODEC)) /* Jz4740: core only */ #define ICODE_ATTR __attribute__ ((section(".icode"))) #define ICONST_ATTR __attribute__ ((section(".irodata"))) #define IDATA_ATTR __attribute__ ((section(".idata"))) #define IBSS_ATTR __attribute__ ((section(".ibss"))) #define USE_IRAM -#if CONFIG_CPU != SH7034 && (CONFIG_CPU != AS3525 || MEMORYSIZE > 2) +#if CONFIG_CPU != SH7034 && (CONFIG_CPU != AS3525 || MEMORYSIZE > 2) && CONFIG_CPU != JZ4732 #define PLUGIN_USE_IRAM #endif #if defined(CPU_ARM) diff --git a/firmware/target/mips/ingenic_jz47xx/app.lds b/firmware/target/mips/ingenic_jz47xx/app.lds index 61bfd2e613..e8c9ebf65b 100644 --- a/firmware/target/mips/ingenic_jz47xx/app.lds +++ b/firmware/target/mips/ingenic_jz47xx/app.lds @@ -16,7 +16,7 @@ STARTUP(target/mips/ingenic_jz47xx/crt0.o) #define DRAMORIG 0x80004000 #define IRAMORIG 0x80000000 -#define IRAMSIZE (16K-0x220) +#define IRAMSIZE 16K /* End of the audio buffer, where the codec buffer starts */ #define ENDAUDIOADDR (DRAMORIG + DRAMSIZE) @@ -41,14 +41,14 @@ SECTIONS *(.init.text); *(.text*); } > DRAM - + . = ALIGN(4); .rodata : { *(.rodata*); } > DRAM - + . = ALIGN(4); .data : @@ -57,9 +57,9 @@ SECTIONS *(.sdata*); *(.rel.dyn); } > DRAM - + . = ALIGN(4); - + /* Set the load address of .iram at the same address as .bss * so RAM won't be wasted as .iram in the end will get copied * to IRAM. */ @@ -74,7 +74,7 @@ SECTIONS . = 0x200; *(.vectors.4); *(.vectors); - + *(.icode); *(.irodata); *(.idata); @@ -83,9 +83,9 @@ SECTIONS _iramend = .; } > IRAM _iramcopy = LOADADDR(.iram); - + . = ALIGN(4); - + .stack (NOLOAD): { *(.stack); @@ -93,28 +93,20 @@ SECTIONS . += 0x2000; stackend = .; } > IRAM - - . = ALIGN(4); .bss (NOLOAD): { _edata = .; *(.sbss*); *(.bss*); + *(.ibss*); /* Don't put this in IRAM as there's not enough space */ *(COMMON); *(.scommon*); _end = .; } > DRAM - + . = ALIGN(4); - - .ibss (NOLOAD) : - { - _iedata = .; - *(.ibss*); - _iend = .; - } > IRAM - + .audiobuf ALIGN(4) : { audiobuffer = .; @@ -134,7 +126,7 @@ SECTIONS { pluginbuf = .; } - + /DISCARD/ : { *(.eh_frame); diff --git a/firmware/target/mips/ingenic_jz47xx/crt0.S b/firmware/target/mips/ingenic_jz47xx/crt0.S index 783773cf0c..111244b173 100644 --- a/firmware/target/mips/ingenic_jz47xx/crt0.S +++ b/firmware/target/mips/ingenic_jz47xx/crt0.S @@ -147,18 +147,6 @@ _bss_loop: sw zero, 0(t0) bne t0, t1, _bss_loop addiu t0, 4 - - /* - ---------------------------------------------------- - Clear IBSS section - ---------------------------------------------------- - */ - la t0, _iedata - la t1, _iend -_ibss_loop: - sw zero, 0(t0) - bne t0, t1, _ibss_loop - addiu t0, 4 /* ---------------------------------------------------- |