1 /* Linker script for mbed LPC1114 */
3 /* Linker script to configure memory regions. */
6 FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 32K
7 RAM (rwx) : ORIGIN = 0x100000C0, LENGTH = 0x0F40
10 /* Linker script to place sections and symbol values. Should be used together
11 * with other linker script that defines memory regions FLASH and RAM.
12 * It references following symbols, which must be defined in code:
13 * Reset_Handler : Entry of reset handler
15 * It defines following symbols, which code can use without definition:
20 * __preinit_array_start
43 *(.text.Reset_Handler)
54 *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors)
61 *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors)
72 *(.ARM.extab* .gnu.linkonce.armextab.*)
78 *(.ARM.exidx* .gnu.linkonce.armexidx.*)
92 PROVIDE (__preinit_array_start = .);
93 KEEP(*(.preinit_array))
94 PROVIDE (__preinit_array_end = .);
98 PROVIDE (__init_array_start = .);
99 KEEP(*(SORT(.init_array.*)))
101 PROVIDE (__init_array_end = .);
106 PROVIDE (__fini_array_start = .);
107 KEEP(*(SORT(.fini_array.*)))
109 PROVIDE (__fini_array_end = .);
133 /* .stack_dummy section doesn't contains any symbols. It is only
134 * used for linker to calculate size of stack sections, and assign
135 * values to stack symbols later */
141 /* Set stack top to end of RAM, and stack limit move down by
142 * size of stack_dummy section */
143 __StackTop = ORIGIN(RAM) + LENGTH(RAM);
144 __StackLimit = __StackTop - SIZEOF(.stack_dummy);
145 PROVIDE(__stack = __StackTop);
147 /* Check if data + heap + stack exceeds RAM limit */
148 ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack")