5 OUTPUT_FORMAT(elf32-m68k)
6 INPUT(target/coldfire/crt0.o)
8 OUTPUT_FORMAT(elf32-littlearm)
11 INPUT(target/arm/crt0-pp.o)
12 #elif defined(OLYMPUS_MROBE_500)
13 INPUT(target/arm/tms320dm320/crt0.o)
14 #elif CONFIG_CPU == PNX0101
15 INPUT(target/arm/pnx0101/crt0-pnx0101.o)
16 #elif defined(CPU_ARM)
17 INPUT(target/arm/crt0.o)
20 OUTPUT_FORMAT(elf32-sh)
21 INPUT(target/sh/crt0.o)
24 #define PLUGINSIZE PLUGIN_BUFFER_SIZE
25 #define CODECSIZE CODEC_SIZE
28 #define STUBOFFSET 0x10000
33 #if CONFIG_CPU==S3C2440
35 #define DRAMSIZE (MEMORYSIZE * 0x100000) - 0x100 - PLUGINSIZE - STUBOFFSET - CODECSIZE - LCD_BUFFER_SIZE - TTB_SIZE
36 #elif CONFIG_CPU==DM320
38 #define DRAMSIZE (MEMORYSIZE * 0x100000) - PLUGINSIZE - STUBOFFSET - CODECSIZE - LCD_BUFFER_SIZE - TTB_SIZE
40 #define DRAMSIZE (MEMORYSIZE * 0x100000) - PLUGINSIZE - STUBOFFSET - CODECSIZE
43 #if defined(IRIVER_H100_SERIES) || defined(IRIVER_H300)
44 #define DRAMORIG 0x31000000 + STUBOFFSET
45 #define IRAMORIG 0x10000000
46 #define IRAMSIZE 0xc000
47 #elif defined(IAUDIO_X5) || defined(IAUDIO_M5)
48 #define DRAMORIG 0x31000000 + STUBOFFSET
49 #define IRAMORIG 0x10000000
50 #define IRAMSIZE 0x10000
52 #define DRAMORIG 0x00000000 + STUBOFFSET
53 #define IRAMORIG 0x40000000
54 #define IRAMSIZE 0xc000
55 #elif CONFIG_CPU==PNX0101
56 #define DRAMORIG 0xc00000 + STUBOFFSET
57 #define IRAM0ORIG 0x000000
58 #define IRAM0SIZE 0x7000
59 #define IRAMORIG 0x400000
60 #define IRAMSIZE 0x7000
61 #elif CONFIG_CPU==S3C2440
62 #define DRAMORIG 0x00000100 + STUBOFFSET
63 #define IRAMORIG DRAMORIG
64 #define IRAMSIZE 0x1000
66 #elif CONFIG_CPU==DM320
67 #define DRAMORIG 0x00900000 + STUBOFFSET
68 #define IRAMORIG 0x00000000
69 #define IRAMSIZE 0x4000
70 #elif CONFIG_CPU==IMX31L
71 #define DRAMORIG (0x80000000 + STUBOFFSET)
72 #define IRAMORIG 0x1FFFC000
73 #define IRAMSIZE 0x4000
75 #define DRAMORIG 0x09000000 + STUBOFFSET
76 #define IRAMORIG 0x0f000000
77 #define IRAMSIZE 0x1000
80 /* End of the audio buffer, where the codec buffer starts */
81 #define ENDAUDIOADDR (DRAMORIG + DRAMSIZE)
83 /* Where the codec buffer ends, and the plugin buffer starts */
84 #define ENDADDR (ENDAUDIOADDR + CODECSIZE)
88 DRAM : ORIGIN = DRAMORIG, LENGTH = DRAMSIZE
89 #if CONFIG_CPU != S3C2440
90 IRAM : ORIGIN = IRAMORIG, LENGTH = IRAMSIZE
92 #if CONFIG_CPU==PNX0101
93 IRAM0 : ORIGIN = IRAM0ORIG, LENGTH = IRAM0SIZE
99 #if (CONFIG_CPU==DM320)
114 *(.rodata) /* problems without this, dunno why */
120 /* Pseudo-allocate the copies of the data sections */
124 /* TRICK ALERT! For RAM execution, we put the .data section at the
125 same load address as the copy. Thus, we don't waste extra RAM
126 when we don't actually need the copy. */
127 .data : AT ( _datacopy )
147 _vectorscopy = LOADADDR(.vectors);
158 _iramcopy = LOADADDR(.iram);
176 .bss ADDR(.data) + SIZEOF(.data) + SIZEOF(.iram) + SIZEOF(.vectors):
185 #else /* End DM320 */
186 #if !defined(CPU_ARM)
191 KEEP(*(.resetvectors));
217 *(.rodata) /* problems without this, dunno why */
223 /* Pseudo-allocate the copies of the data sections */
227 /* TRICK ALERT! For RAM execution, we put the .data section at the
228 same load address as the copy. Thus, we don't waste extra RAM
229 when we don't actually need the copy. */
230 .data : AT ( _datacopy )
244 #if CONFIG_CPU==DM320
253 #if CONFIG_CPU==PNX0101
256 #elif CONFIG_CPU==DM320
262 _vectorscopy = LOADADDR(.vectors);
265 #if CONFIG_CPU==PNX0101
266 .iram IRAMORIG + SIZEOF(.vectors) :
267 #elif CONFIG_CPU==S3C2440 || CONFIG_CPU==DM320
280 _iramcopy = LOADADDR(.iram);
290 #if defined(CPU_COLDFIRE) || defined(CPU_ARM)
304 cpu_idlestackbegin = .;
305 . += IDLE_STACK_SIZE;
306 cpu_idlestackend = .;
308 cop_idlestackbegin = .;
309 . += IDLE_STACK_SIZE;
310 cop_idlestackend = .;
315 /* TRICK ALERT! We want 0x2000 bytes of stack, but we set the section
316 size smaller, and allow the stack to grow into the .iram copy */
317 .stack ADDR(.data) + SIZEOF(.data) + SIZEOF(.iram):
320 _stackbegin = . - SIZEOF(.iram);
321 . += 0x2000 - SIZEOF(.iram);
326 #if defined(CPU_COLDFIRE)
327 .bss ADDR(.data) + SIZEOF(.data) + SIZEOF(.iram):
328 #elif defined(CPU_ARM) && CONFIG_CPU != S3C2440
329 .bss ADDR(.data) + SIZEOF(.data) + SIZEOF(.iram) + SIZEOF(.vectors):
349 .audiobufend ENDAUDIOADDR: