2020-04-11 20:19:39 +08:00
|
|
|
ENTRY(_boot_cores);
|
|
|
|
|
|
|
|
STACK_SIZE = 0x8000;
|
2020-04-28 19:07:49 +08:00
|
|
|
HEAP_SIZE = 0x1000000;
|
2020-04-11 20:19:39 +08:00
|
|
|
|
|
|
|
/* Provide some defaults */
|
|
|
|
PROVIDE(Reset = _boot_cores);
|
|
|
|
PROVIDE(UndefinedInstruction = Reset);
|
|
|
|
PROVIDE(SoftwareInterrupt = Reset);
|
|
|
|
PROVIDE(PrefetchAbort = Reset);
|
|
|
|
PROVIDE(DataAbort = Reset);
|
|
|
|
PROVIDE(ReservedException = Reset);
|
|
|
|
PROVIDE(IRQ = Reset);
|
|
|
|
PROVIDE(FIQ = Reset);
|
|
|
|
|
|
|
|
MEMORY
|
|
|
|
{
|
2020-04-28 19:07:49 +08:00
|
|
|
SDRAM : ORIGIN = 0x00100000, LENGTH = 0x1FF00000
|
2020-04-11 20:19:39 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
SECTIONS
|
|
|
|
{
|
|
|
|
.text :
|
|
|
|
{
|
|
|
|
KEEP(*(.text.exceptions));
|
|
|
|
*(.text.boot);
|
|
|
|
*(.text .text.*);
|
2020-04-28 19:07:49 +08:00
|
|
|
} > SDRAM
|
2020-04-11 20:19:39 +08:00
|
|
|
|
|
|
|
.rodata : ALIGN(4)
|
|
|
|
{
|
|
|
|
*(.rodata .rodata.*);
|
2020-04-28 19:07:49 +08:00
|
|
|
} > SDRAM
|
2020-04-11 20:19:39 +08:00
|
|
|
|
|
|
|
.data : ALIGN(4)
|
|
|
|
{
|
|
|
|
*(.data .data.*);
|
2020-04-28 19:07:49 +08:00
|
|
|
} > SDRAM
|
2020-04-11 20:19:39 +08:00
|
|
|
|
|
|
|
.bss (NOLOAD) : ALIGN(0x4000)
|
|
|
|
{
|
|
|
|
/* Aligned to 16 kB */
|
|
|
|
KEEP(*(.bss.l1_table));
|
|
|
|
*(.bss .bss.*);
|
|
|
|
. = ALIGN(4);
|
2020-04-28 19:07:49 +08:00
|
|
|
} > SDRAM
|
2020-04-11 20:19:39 +08:00
|
|
|
__bss_start = ADDR(.bss);
|
|
|
|
__bss_end = ADDR(.bss) + SIZEOF(.bss);
|
|
|
|
|
2020-04-28 19:07:49 +08:00
|
|
|
.heap (NOLOAD) : ALIGN(0x1000)
|
|
|
|
{
|
|
|
|
. += HEAP_SIZE;
|
|
|
|
} > SDRAM
|
|
|
|
__heap_start = ADDR(.heap);
|
|
|
|
__heap_end = ADDR(.heap) + SIZEOF(.heap);
|
|
|
|
|
|
|
|
.stack (NOLOAD) : ALIGN(0x1000)
|
|
|
|
{
|
|
|
|
. += STACK_SIZE;
|
|
|
|
} > SDRAM
|
2020-04-11 20:19:39 +08:00
|
|
|
__stack_end = ADDR(.stack);
|
|
|
|
__stack_start = ADDR(.stack) + SIZEOF(.stack);
|
|
|
|
|
|
|
|
/DISCARD/ :
|
|
|
|
{
|
|
|
|
/* Unused exception related info that only wastes space */
|
|
|
|
*(.ARM.exidx);
|
|
|
|
*(.ARM.exidx.*);
|
|
|
|
*(.ARM.extab.*);
|
|
|
|
}
|
|
|
|
}
|