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 IRAMORIG 0x400000
58 #define IRAMSIZE 0x7000
59 #elif CONFIG_CPU==S3C2440
60 #define DRAMORIG 0x00000100 + STUBOFFSET
61 #define IRAMORIG DRAMORIG
62 #define IRAMSIZE 0x1000
64 #elif CONFIG_CPU==DM320
65 #define DRAMORIG 0x00900000 + STUBOFFSET
66 #define IRAMORIG 0x00000000
67 #define IRAMSIZE 0x4000
68 #elif CONFIG_CPU==IMX31L
69 #define DRAMORIG (0x80000000 + STUBOFFSET)
70 #define IRAMORIG 0x1FFFC000
71 #define IRAMSIZE 0x4000
73 #define DRAMORIG 0x09000000 + STUBOFFSET
74 #define IRAMORIG 0x0f000000
75 #define IRAMSIZE 0x1000
78 /* End of the audio buffer, where the codec buffer starts */
79 #define ENDAUDIOADDR (DRAMORIG + DRAMSIZE)
81 /* Where the codec buffer ends, and the plugin buffer starts */
82 #define ENDADDR (ENDAUDIOADDR + CODECSIZE)
86 DRAM : ORIGIN = DRAMORIG, LENGTH = DRAMSIZE
87 #if CONFIG_CPU != S3C2440
88 IRAM : ORIGIN = IRAMORIG, LENGTH = IRAMSIZE
90 #if CONFIG_CPU==PNX0101
91 IRAM0 : ORIGIN = 0x0, LENGTH = IRAMSIZE
102 KEEP(*(.resetvectors));
128 *(.rodata) /* problems without this, dunno why */
134 /* Pseudo-allocate the copies of the data sections */
138 /* TRICK ALERT! For RAM execution, we put the .data section at the
139 same load address as the copy. Thus, we don't waste extra RAM
140 when we don't actually need the copy. */
141 .data : AT ( _datacopy )
155 #if CONFIG_CPU==DM320
164 #if CONFIG_CPU==PNX0101
167 #elif CONFIG_CPU==DM320
173 _vectorscopy = LOADADDR(.vectors);
176 #if CONFIG_CPU==PNX0101
177 .iram IRAMORIG + SIZEOF(.vectors) :
178 #elif CONFIG_CPU==S3C2440 || CONFIG_CPU==DM320
191 _iramcopy = LOADADDR(.iram);
201 #if defined(CPU_COLDFIRE) || defined(CPU_ARM)
215 cpu_idlestackbegin = .;
216 . += IDLE_STACK_SIZE;
217 cpu_idlestackend = .;
219 cop_idlestackbegin = .;
220 . += IDLE_STACK_SIZE;
221 cop_idlestackend = .;
226 /* TRICK ALERT! We want 0x2000 bytes of stack, but we set the section
227 size smaller, and allow the stack to grow into the .iram copy */
228 .stack ADDR(.data) + SIZEOF(.data) + SIZEOF(.iram):
231 _stackbegin = . - SIZEOF(.iram);
232 . += 0x2000 - SIZEOF(.iram);
237 #if defined(CPU_COLDFIRE)
238 .bss ADDR(.data) + SIZEOF(.data) + SIZEOF(.iram):
239 #elif defined(CPU_ARM) && CONFIG_CPU != S3C2440
240 .bss ADDR(.data) + SIZEOF(.data) + SIZEOF(.iram) + SIZEOF(.vectors):
258 .audiobufend ENDAUDIOADDR: