2008-05-02 19:12:09 +00:00
|
|
|
#include "config.h"
|
|
|
|
|
|
|
|
ENTRY(start)
|
|
|
|
OUTPUT_FORMAT(elf32-littlearm)
|
|
|
|
OUTPUT_ARCH(arm)
|
|
|
|
STARTUP(target/arm/tcc77x/crt0.o)
|
|
|
|
|
|
|
|
#define PLUGINSIZE PLUGIN_BUFFER_SIZE
|
|
|
|
#define CODECSIZE CODEC_SIZE
|
|
|
|
|
2010-09-20 17:09:55 +00:00
|
|
|
#define DRAMSIZE (MEMORYSIZE * 0x100000) - PLUGINSIZE - CODECSIZE
|
2008-05-02 19:12:09 +00:00
|
|
|
|
|
|
|
#define DRAMORIG 0x20000000
|
|
|
|
#define IRAMORIG 0x00000000
|
2008-09-06 17:50:59 +00:00
|
|
|
#define IRAMSIZE 64K
|
|
|
|
|
2008-05-02 19:12:09 +00:00
|
|
|
|
|
|
|
/* End of the audio buffer, where the codec buffer starts */
|
|
|
|
#define ENDAUDIOADDR (DRAMORIG + DRAMSIZE)
|
|
|
|
|
|
|
|
/* Where the codec buffer ends, and the plugin buffer starts */
|
|
|
|
#define ENDADDR (ENDAUDIOADDR + CODECSIZE)
|
|
|
|
|
2008-09-06 17:50:59 +00:00
|
|
|
|
2008-05-02 19:12:09 +00:00
|
|
|
MEMORY
|
|
|
|
{
|
2008-09-06 17:50:59 +00:00
|
|
|
#ifdef TCCBOOT
|
|
|
|
DRAM : ORIGIN = DRAMORIG + DRAMSIZE - 0x100000, LENGTH = 0x100000
|
|
|
|
#else
|
|
|
|
DRAM : ORIGIN = DRAMORIG, LENGTH = DRAMSIZE
|
|
|
|
#endif
|
|
|
|
IRAM : ORIGIN = IRAMORIG, LENGTH = IRAMSIZE
|
2008-05-02 19:12:09 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
SECTIONS
|
|
|
|
{
|
2008-09-06 17:50:59 +00:00
|
|
|
.text : {
|
|
|
|
loadaddress = .;
|
|
|
|
_loadaddress = .;
|
|
|
|
. = ALIGN(0x200);
|
2008-05-02 19:12:09 +00:00
|
|
|
*(.init.text)
|
2008-09-06 17:50:59 +00:00
|
|
|
*(.text)
|
2008-05-02 19:12:09 +00:00
|
|
|
*(.text*)
|
|
|
|
*(.glue_7)
|
|
|
|
*(.glue_7t)
|
2008-09-06 17:50:59 +00:00
|
|
|
} > DRAM
|
2008-05-02 19:12:09 +00:00
|
|
|
|
2008-09-06 17:50:59 +00:00
|
|
|
.data : {
|
2008-05-02 19:12:09 +00:00
|
|
|
*(.icode)
|
|
|
|
*(.irodata)
|
|
|
|
*(.idata)
|
2008-09-06 17:50:59 +00:00
|
|
|
*(.data*)
|
|
|
|
*(.rodata.*)
|
|
|
|
*(.rodata)
|
2008-05-02 19:12:09 +00:00
|
|
|
. = ALIGN(0x4);
|
2008-09-06 17:50:59 +00:00
|
|
|
_dataend = . ;
|
2008-05-02 19:12:09 +00:00
|
|
|
} > DRAM
|
|
|
|
|
|
|
|
.stack :
|
|
|
|
{
|
2008-09-06 17:50:59 +00:00
|
|
|
*(.stack)
|
|
|
|
_stackbegin = .;
|
|
|
|
stackbegin = .;
|
|
|
|
. += 0x2000;
|
|
|
|
_stackend = .;
|
|
|
|
stackend = .;
|
2008-05-02 19:12:09 +00:00
|
|
|
} > DRAM
|
|
|
|
|
2008-09-06 17:50:59 +00:00
|
|
|
.bss : {
|
|
|
|
_edata = .;
|
|
|
|
*(.bss*);
|
|
|
|
*(.ibss);
|
|
|
|
*(COMMON)
|
|
|
|
_end = .;
|
|
|
|
} > DRAM
|
2008-05-02 19:12:09 +00:00
|
|
|
.audiobuf ALIGN(4) :
|
|
|
|
{
|
|
|
|
_audiobuffer = .;
|
|
|
|
audiobuffer = .;
|
|
|
|
} > DRAM
|
|
|
|
|
|
|
|
.audiobufend ENDAUDIOADDR:
|
|
|
|
{
|
|
|
|
audiobufend = .;
|
|
|
|
_audiobufend = .;
|
|
|
|
} > DRAM
|
2008-09-06 17:50:59 +00:00
|
|
|
|
2008-05-02 19:12:09 +00:00
|
|
|
.codec ENDAUDIOADDR:
|
|
|
|
{
|
|
|
|
codecbuf = .;
|
|
|
|
_codecbuf = .;
|
|
|
|
}
|
|
|
|
|
|
|
|
.plugin ENDADDR:
|
|
|
|
{
|
|
|
|
_pluginbuf = .;
|
|
|
|
pluginbuf = .;
|
2008-09-06 17:50:59 +00:00
|
|
|
}
|
2008-05-02 19:12:09 +00:00
|
|
|
}
|