summaryrefslogtreecommitdiff
path: root/firmware/target/mips
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/target/mips')
-rw-r--r--firmware/target/mips/ingenic_jz47xx/app.lds34
1 files changed, 10 insertions, 24 deletions
diff --git a/firmware/target/mips/ingenic_jz47xx/app.lds b/firmware/target/mips/ingenic_jz47xx/app.lds
index e8c9ebf65b..bd924e44f4 100644
--- a/firmware/target/mips/ingenic_jz47xx/app.lds
+++ b/firmware/target/mips/ingenic_jz47xx/app.lds
@@ -12,17 +12,17 @@ STARTUP(target/mips/ingenic_jz47xx/crt0.o)
12#define STUBOFFSET 0 12#define STUBOFFSET 0
13#endif 13#endif
14 14
15#define DRAMSIZE (MEMORYSIZE * 0x100000) - PLUGIN_BUFFER_SIZE - STUBOFFSET - CODEC_SIZE
16 15
17#define DRAMORIG 0x80004000 16#define DRAMORIG 0x80004000 + STUBOFFSET
17#define DRAMSIZE (MEMORYSIZE * 0x100000 - STUBOFFSET)
18#define IRAMORIG 0x80000000 18#define IRAMORIG 0x80000000
19#define IRAMSIZE 16K 19#define IRAMSIZE 16K
20 20
21/* End of the audio buffer, where the codec buffer starts */ 21/* End of the audio buffer, where the codec buffer starts */
22#define ENDAUDIOADDR (DRAMORIG + DRAMSIZE) 22#define ENDAUDIOADDR (DRAMORIG + DRAMSIZE - PLUGIN_BUFFER_SIZE - CODEC_SIZE)
23 23
24/* Where the codec buffer ends, and the plugin buffer starts */ 24/* Where the codec buffer ends, and the plugin buffer starts */
25#define ENDADDR (ENDAUDIOADDR + CODEC_SIZE) 25#define ENDCODECADDR (ENDAUDIOADDR + CODEC_SIZE)
26 26
27MEMORY 27MEMORY
28{ 28{
@@ -55,11 +55,8 @@ SECTIONS
55 { 55 {
56 *(.data*); 56 *(.data*);
57 *(.sdata*); 57 *(.sdata*);
58 *(.rel.dyn);
59 } > DRAM 58 } > DRAM
60 59
61 . = ALIGN(4);
62
63 /* Set the load address of .iram at the same address as .bss 60 /* Set the load address of .iram at the same address as .bss
64 * so RAM won't be wasted as .iram in the end will get copied 61 * so RAM won't be wasted as .iram in the end will get copied
65 * to IRAM. */ 62 * to IRAM. */
@@ -105,30 +102,19 @@ SECTIONS
105 _end = .; 102 _end = .;
106 } > DRAM 103 } > DRAM
107 104
108 . = ALIGN(4); 105 .audiobuf :
109
110 .audiobuf ALIGN(4) :
111 { 106 {
107 . = ALIGN(4);
112 audiobuffer = .; 108 audiobuffer = .;
113 } > DRAM 109 } > DRAM
114 110
115 .audiobufend ENDAUDIOADDR: 111 audiobufend = ENDAUDIOADDR;
116 { 112 codecbuf = ENDAUDIOADDR;
117 audiobufend = .; 113 pluginbuf = ENDCODECADDR;
118 }
119
120 .codec ENDAUDIOADDR:
121 {
122 codecbuf = .;
123 }
124
125 .plugin ENDADDR:
126 {
127 pluginbuf = .;
128 }
129 114
130 /DISCARD/ : 115 /DISCARD/ :
131 { 116 {
132 *(.eh_frame); 117 *(.eh_frame);
118 *(.rel.dyn);
133 } 119 }
134} 120}