2008-03-27 23:58:03 +00:00
|
|
|
#include "config.h"
|
|
|
|
|
|
|
|
ENTRY(start)
|
|
|
|
OUTPUT_FORMAT(elf32-littlearm)
|
|
|
|
OUTPUT_ARCH(arm)
|
2008-04-29 06:19:32 +00:00
|
|
|
STARTUP(target/arm/tcc77x/crt0.o)
|
2008-03-27 23:58:03 +00:00
|
|
|
|
|
|
|
#define DRAMSIZE (MEMORYSIZE * 0x100000)
|
|
|
|
|
|
|
|
#define DRAMORIG 0x20000000
|
|
|
|
#define IRAMORIG 0x00000000
|
|
|
|
#define IRAMSIZE 64K
|
2008-05-02 19:12:09 +00:00
|
|
|
|
2008-03-27 23:58:03 +00:00
|
|
|
|
|
|
|
MEMORY
|
|
|
|
{
|
2008-09-06 17:50:59 +00:00
|
|
|
#ifdef TCCBOOT
|
2008-03-27 23:58:03 +00:00
|
|
|
DRAM : ORIGIN = DRAMORIG + DRAMSIZE - 0x100000, LENGTH = 0x100000
|
2008-09-06 17:50:59 +00:00
|
|
|
#else
|
|
|
|
DRAM : ORIGIN = DRAMORIG, LENGTH = DRAMSIZE
|
|
|
|
#endif
|
2008-03-27 23:58:03 +00:00
|
|
|
IRAM : ORIGIN = IRAMORIG, LENGTH = IRAMSIZE
|
|
|
|
}
|
|
|
|
|
|
|
|
SECTIONS
|
|
|
|
{
|
|
|
|
.text : {
|
|
|
|
*(.init.text)
|
|
|
|
*(.text)
|
|
|
|
*(.text*)
|
|
|
|
*(.glue_7)
|
|
|
|
*(.glue_7t)
|
|
|
|
} > DRAM
|
|
|
|
|
|
|
|
.data : {
|
|
|
|
*(.icode)
|
|
|
|
*(.irodata)
|
|
|
|
*(.idata)
|
|
|
|
*(.data*)
|
|
|
|
*(.rodata.*)
|
2008-09-06 17:50:59 +00:00
|
|
|
*(.rodata)
|
2008-03-27 23:58:03 +00:00
|
|
|
. = ALIGN(0x4);
|
|
|
|
_dataend = . ;
|
|
|
|
} > DRAM
|
|
|
|
|
2010-03-08 23:16:57 +00:00
|
|
|
.stack (NOLOAD) :
|
2008-03-27 23:58:03 +00:00
|
|
|
{
|
|
|
|
*(.stack)
|
|
|
|
_stackbegin = .;
|
|
|
|
stackbegin = .;
|
|
|
|
. += 0x2000;
|
|
|
|
_stackend = .;
|
|
|
|
stackend = .;
|
|
|
|
} > DRAM
|
2008-05-02 19:12:09 +00:00
|
|
|
|
2010-03-08 23:16:57 +00:00
|
|
|
.bss (NOLOAD) : {
|
2008-03-27 23:58:03 +00:00
|
|
|
_edata = .;
|
|
|
|
*(.bss*);
|
|
|
|
*(.ibss);
|
|
|
|
*(COMMON)
|
|
|
|
_end = .;
|
|
|
|
} > DRAM
|
|
|
|
}
|