Fork of the official mbed C/C SDK provides the software platform and libraries to build your applications for RenBED.
Dependents: 1-RenBuggyTimed RenBED_RGB RenBED_RGB_PWM RenBED_RGB
Fork of mbed by
TARGET_LPC2460/TOOLCHAIN_GCC_ARM/LPC2460.ld@121:672067c3ada4, 2016-04-14 (annotated)
- Committer:
- elijahorr
- Date:
- Thu Apr 14 07:28:54 2016 +0000
- Revision:
- 121:672067c3ada4
- Parent:
- 102:da0ca467f8b5
.
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
Kojto | 102:da0ca467f8b5 | 1 | OUTPUT_FORMAT("elf32-littlearm", "elf32-bigarm", "elf32-littlearm") |
Kojto | 102:da0ca467f8b5 | 2 | OUTPUT_ARCH(arm) |
Kojto | 102:da0ca467f8b5 | 3 | ENTRY(vectors) |
Kojto | 102:da0ca467f8b5 | 4 | |
Kojto | 102:da0ca467f8b5 | 5 | /* Memory Definitions: */ |
Kojto | 102:da0ca467f8b5 | 6 | MEMORY |
Kojto | 102:da0ca467f8b5 | 7 | { |
Kojto | 102:da0ca467f8b5 | 8 | Flash (rx) : ORIGIN = 0xA0001000, LENGTH = 512k |
Kojto | 102:da0ca467f8b5 | 9 | Ram (rwx) : ORIGIN = 0x40000040, LENGTH = 64k - 0x40 |
Kojto | 102:da0ca467f8b5 | 10 | UsbRam (rw) : ORIGIN = 0x7FD00000, LENGTH = 8k |
Kojto | 102:da0ca467f8b5 | 11 | EthRam (rw) : ORIGIN = 0x7FE00000, LENGTH = 16k |
Kojto | 102:da0ca467f8b5 | 12 | CanRam (rw) : ORIGIN = 0xE0038000, LENGTH = 2k |
Kojto | 102:da0ca467f8b5 | 13 | BatRam (rw) : ORIGIN = 0xE0084000, LENGTH = 2k |
Kojto | 102:da0ca467f8b5 | 14 | } |
Kojto | 102:da0ca467f8b5 | 15 | |
Kojto | 102:da0ca467f8b5 | 16 | /* Stack sizes: */ |
Kojto | 102:da0ca467f8b5 | 17 | UND_Stack_Size = 64; |
Kojto | 102:da0ca467f8b5 | 18 | SVC_Stack_Size = 64; |
Kojto | 102:da0ca467f8b5 | 19 | ABT_Stack_Size = 64; |
Kojto | 102:da0ca467f8b5 | 20 | FIQ_Stack_Size = 64; |
Kojto | 102:da0ca467f8b5 | 21 | IRQ_Stack_Size = 64; |
Kojto | 102:da0ca467f8b5 | 22 | User_Stack_Size = 4096; |
Kojto | 102:da0ca467f8b5 | 23 | Stack_Size_Total = UND_Stack_Size + SVC_Stack_Size + ABT_Stack_Size + FIQ_Stack_Size + IRQ_Stack_Size + User_Stack_Size; |
Kojto | 102:da0ca467f8b5 | 24 | |
Kojto | 102:da0ca467f8b5 | 25 | /* Stack tops for each mode: */ |
Kojto | 102:da0ca467f8b5 | 26 | __und_stack_top__ = __stacks_top__; |
Kojto | 102:da0ca467f8b5 | 27 | __abt_stack_top__ = __und_stack_top__ - UND_Stack_Size ; |
Kojto | 102:da0ca467f8b5 | 28 | __fiq_stack_top__ = __abt_stack_top__ - ABT_Stack_Size ; |
Kojto | 102:da0ca467f8b5 | 29 | __irq_stack_top__ = __fiq_stack_top__ - FIQ_Stack_Size ; |
Kojto | 102:da0ca467f8b5 | 30 | __svc_stack_top__ = __irq_stack_top__ - IRQ_Stack_Size ; |
Kojto | 102:da0ca467f8b5 | 31 | __usr_stack_top__ = __svc_stack_top__ - User_Stack_Size ; |
Kojto | 102:da0ca467f8b5 | 32 | |
Kojto | 102:da0ca467f8b5 | 33 | /* C-accessible symbols for memory address ranges: */ |
Kojto | 102:da0ca467f8b5 | 34 | __FLASH_segment_start__ = ORIGIN( Flash ); |
Kojto | 102:da0ca467f8b5 | 35 | __FLASH_segment_end__ = ORIGIN( Flash ) + LENGTH( Flash ); |
Kojto | 102:da0ca467f8b5 | 36 | __SRAM_segment_start__ = ORIGIN( Ram ); |
Kojto | 102:da0ca467f8b5 | 37 | __SRAM_segment_end__ = ORIGIN( Ram ) + LENGTH( Ram ); |
Kojto | 102:da0ca467f8b5 | 38 | |
Kojto | 102:da0ca467f8b5 | 39 | /* Stacks (full descending) at top of RAM, grows downward: |
Kojto | 102:da0ca467f8b5 | 40 | * |
Kojto | 102:da0ca467f8b5 | 41 | * __stack_min__ is used by the malloc implementation to ensure heap never collides |
Kojto | 102:da0ca467f8b5 | 42 | * with stack (assuming stack never grows beyond Stack_Size_Total in length) */ |
Kojto | 102:da0ca467f8b5 | 43 | __stacks_top__ = __SRAM_segment_end__; |
Kojto | 102:da0ca467f8b5 | 44 | __stacks_min__ = __SRAM_segment_end__ - Stack_Size_Total; |
Kojto | 102:da0ca467f8b5 | 45 | |
Kojto | 102:da0ca467f8b5 | 46 | SECTIONS |
Kojto | 102:da0ca467f8b5 | 47 | { |
Kojto | 102:da0ca467f8b5 | 48 | /* first section is .text which is used for code */ |
Kojto | 102:da0ca467f8b5 | 49 | __text_start__ = . ; |
Kojto | 102:da0ca467f8b5 | 50 | .text : { |
Kojto | 102:da0ca467f8b5 | 51 | __privileged_code_start__ = . ; |
Kojto | 102:da0ca467f8b5 | 52 | KEEP( *( .vectors ) ) |
Kojto | 102:da0ca467f8b5 | 53 | *( .privileged_code ) |
Kojto | 102:da0ca467f8b5 | 54 | |
Kojto | 102:da0ca467f8b5 | 55 | __privileged_code_end__ = .; |
Kojto | 102:da0ca467f8b5 | 56 | |
Kojto | 102:da0ca467f8b5 | 57 | *( .text .text.* .gnu.linkonce.t.* ) |
Kojto | 102:da0ca467f8b5 | 58 | *( .plt ) |
Kojto | 102:da0ca467f8b5 | 59 | *( .gnu.warning ) |
Kojto | 102:da0ca467f8b5 | 60 | *( .glue_7t ) *( .glue_7 ) *( .vfp11_veneer ) |
Kojto | 102:da0ca467f8b5 | 61 | |
Kojto | 102:da0ca467f8b5 | 62 | *( .rodata .rodata.* .gnu.linkonce.r.* ) |
Kojto | 102:da0ca467f8b5 | 63 | |
Kojto | 102:da0ca467f8b5 | 64 | *(.ARM.extab* .gnu.linkonce.armextab.*) |
Kojto | 102:da0ca467f8b5 | 65 | *(.gcc_except_table) |
Kojto | 102:da0ca467f8b5 | 66 | *(.eh_frame_hdr) |
Kojto | 102:da0ca467f8b5 | 67 | *(.eh_frame) |
Kojto | 102:da0ca467f8b5 | 68 | |
Kojto | 102:da0ca467f8b5 | 69 | . = ALIGN( 4 ) ; |
Kojto | 102:da0ca467f8b5 | 70 | KEEP( *( .init ) ) |
Kojto | 102:da0ca467f8b5 | 71 | . = ALIGN( 4 ) ; |
Kojto | 102:da0ca467f8b5 | 72 | __preinit_array_start = . ; |
Kojto | 102:da0ca467f8b5 | 73 | KEEP( *( .preinit_array ) ) |
Kojto | 102:da0ca467f8b5 | 74 | __preinit_array_end = . ; |
Kojto | 102:da0ca467f8b5 | 75 | . = ALIGN( 4 ) ; |
Kojto | 102:da0ca467f8b5 | 76 | __init_array_start = . ; |
Kojto | 102:da0ca467f8b5 | 77 | KEEP( *( SORT( .init_array.* ) ) ) |
Kojto | 102:da0ca467f8b5 | 78 | KEEP( *( .init_array ) ) |
Kojto | 102:da0ca467f8b5 | 79 | __init_array_end = . ; |
Kojto | 102:da0ca467f8b5 | 80 | |
Kojto | 102:da0ca467f8b5 | 81 | . = ALIGN( 4 ) ; |
Kojto | 102:da0ca467f8b5 | 82 | KEEP( *crtbegin.o( .ctors ) ) |
Kojto | 102:da0ca467f8b5 | 83 | KEEP( *( EXCLUDE_FILE( *crtend.o ) .ctors ) ) |
Kojto | 102:da0ca467f8b5 | 84 | KEEP( *( SORT( .ctors.* ) ) ) |
Kojto | 102:da0ca467f8b5 | 85 | KEEP( *crtend.o( .ctors ) ) |
Kojto | 102:da0ca467f8b5 | 86 | |
Kojto | 102:da0ca467f8b5 | 87 | . = ALIGN( 4 ) ; |
Kojto | 102:da0ca467f8b5 | 88 | KEEP( *( .fini ) ) |
Kojto | 102:da0ca467f8b5 | 89 | . = ALIGN( 4 ) ; |
Kojto | 102:da0ca467f8b5 | 90 | __fini_array_start = . ; |
Kojto | 102:da0ca467f8b5 | 91 | KEEP( *( .fini_array ) ) |
Kojto | 102:da0ca467f8b5 | 92 | KEEP( *( SORT( .fini_array.* ) ) ) |
Kojto | 102:da0ca467f8b5 | 93 | __fini_array_end = . ; |
Kojto | 102:da0ca467f8b5 | 94 | |
Kojto | 102:da0ca467f8b5 | 95 | KEEP( *crtbegin.o( .dtors ) ) |
Kojto | 102:da0ca467f8b5 | 96 | KEEP( *( EXCLUDE_FILE( *crtend.o ) .dtors ) ) |
Kojto | 102:da0ca467f8b5 | 97 | KEEP( *( SORT( .dtors.* ) ) ) |
Kojto | 102:da0ca467f8b5 | 98 | KEEP( *crtend.o( .dtors ) ) |
Kojto | 102:da0ca467f8b5 | 99 | |
Kojto | 102:da0ca467f8b5 | 100 | } >Flash |
Kojto | 102:da0ca467f8b5 | 101 | |
Kojto | 102:da0ca467f8b5 | 102 | __exidx_start = . ; |
Kojto | 102:da0ca467f8b5 | 103 | .ARM.exidx : { |
Kojto | 102:da0ca467f8b5 | 104 | *( .ARM.exidx* .gnu.linkonce.armexidx.* ) |
Kojto | 102:da0ca467f8b5 | 105 | } >Flash |
Kojto | 102:da0ca467f8b5 | 106 | __exidx_end = . ; |
Kojto | 102:da0ca467f8b5 | 107 | |
Kojto | 102:da0ca467f8b5 | 108 | .text.align : { . = ALIGN( 8 ) ; } >Flash /* Alignment schenanigans */ |
Kojto | 102:da0ca467f8b5 | 109 | __text_end__ = . ; |
Kojto | 102:da0ca467f8b5 | 110 | |
Kojto | 102:da0ca467f8b5 | 111 | /* .bss section -- used for uninitialized data */ |
Kojto | 102:da0ca467f8b5 | 112 | /* Located at the start of RAM */ |
Kojto | 102:da0ca467f8b5 | 113 | .bss (NOLOAD) : { |
Kojto | 102:da0ca467f8b5 | 114 | __bss_start__ = . ; |
Kojto | 102:da0ca467f8b5 | 115 | *crt0.o( .ram_vectors ) |
Kojto | 102:da0ca467f8b5 | 116 | |
Kojto | 102:da0ca467f8b5 | 117 | __user_bss_start__ = . ; |
Kojto | 102:da0ca467f8b5 | 118 | *( .user_bss ) |
Kojto | 102:da0ca467f8b5 | 119 | __user_bss_end__ = . ; |
Kojto | 102:da0ca467f8b5 | 120 | |
Kojto | 102:da0ca467f8b5 | 121 | *( .shbss ) |
Kojto | 102:da0ca467f8b5 | 122 | *( .bss .bss.* .gnu.linkonce.b.* ) |
Kojto | 102:da0ca467f8b5 | 123 | *( COMMON ) |
Kojto | 102:da0ca467f8b5 | 124 | *( .ram.b ) |
Kojto | 102:da0ca467f8b5 | 125 | . = ALIGN( 8 ) ; |
Kojto | 102:da0ca467f8b5 | 126 | |
Kojto | 102:da0ca467f8b5 | 127 | __bss_end__ = . ; |
Kojto | 102:da0ca467f8b5 | 128 | } >Ram AT>Flash |
Kojto | 102:da0ca467f8b5 | 129 | |
Kojto | 102:da0ca467f8b5 | 130 | /* .data section -- used for initialized data */ |
Kojto | 102:da0ca467f8b5 | 131 | .data : { |
Kojto | 102:da0ca467f8b5 | 132 | __data_start__ = . ; |
Kojto | 102:da0ca467f8b5 | 133 | KEEP( *( .jcr ) ) |
Kojto | 102:da0ca467f8b5 | 134 | *( .got.plt ) *( .got ) |
Kojto | 102:da0ca467f8b5 | 135 | *( .shdata ) |
Kojto | 102:da0ca467f8b5 | 136 | *( .data .data.* .gnu.linkonce.d.* ) |
Kojto | 102:da0ca467f8b5 | 137 | *( .ram ) |
Kojto | 102:da0ca467f8b5 | 138 | . = ALIGN( 8 ) ; |
Kojto | 102:da0ca467f8b5 | 139 | __data_end__ = . ; |
Kojto | 102:da0ca467f8b5 | 140 | } >Ram AT>Flash |
Kojto | 102:da0ca467f8b5 | 141 | |
Kojto | 102:da0ca467f8b5 | 142 | __data_init_start__ = LOADADDR( .data ) ; |
Kojto | 102:da0ca467f8b5 | 143 | |
Kojto | 102:da0ca467f8b5 | 144 | /* Heap starts here and grows up in memory */ |
Kojto | 102:da0ca467f8b5 | 145 | . = ALIGN( 8 ) ; |
Kojto | 102:da0ca467f8b5 | 146 | __heap_start__ = . ; |
Kojto | 102:da0ca467f8b5 | 147 | end = . ; |
Kojto | 102:da0ca467f8b5 | 148 | __end__ = . ; |
Kojto | 102:da0ca467f8b5 | 149 | |
Kojto | 102:da0ca467f8b5 | 150 | .stab 0 (NOLOAD) : { *(.stab) } |
Kojto | 102:da0ca467f8b5 | 151 | .stabstr 0 (NOLOAD) : { *(.stabstr) } |
Kojto | 102:da0ca467f8b5 | 152 | /* DWARF debug sections. */ |
Kojto | 102:da0ca467f8b5 | 153 | /* Symbols in the DWARF debugging sections are relative to the */ |
Kojto | 102:da0ca467f8b5 | 154 | /* beginning of the section so we begin them at 0. */ |
Kojto | 102:da0ca467f8b5 | 155 | /* DWARF 1 */ |
Kojto | 102:da0ca467f8b5 | 156 | .debug 0 : { *(.debug) } |
Kojto | 102:da0ca467f8b5 | 157 | .line 0 : { *(.line) } |
Kojto | 102:da0ca467f8b5 | 158 | /* GNU DWARF 1 extensions */ |
Kojto | 102:da0ca467f8b5 | 159 | .debug_srcinfo 0 : { *(.debug_srcinfo) } |
Kojto | 102:da0ca467f8b5 | 160 | .debug_sfnames 0 : { *(.debug_sfnames) } |
Kojto | 102:da0ca467f8b5 | 161 | /* DWARF 1.1 and DWARF 2 */ |
Kojto | 102:da0ca467f8b5 | 162 | .debug_aranges 0 : { *(.debug_aranges) } |
Kojto | 102:da0ca467f8b5 | 163 | .debug_pubnames 0 : { *(.debug_pubnames) } |
Kojto | 102:da0ca467f8b5 | 164 | /* DWARF 2 */ |
Kojto | 102:da0ca467f8b5 | 165 | .debug_info 0 : { *(.debug_info .gnu.linkonce.wi.*) } |
Kojto | 102:da0ca467f8b5 | 166 | .debug_abbrev 0 : { *(.debug_abbrev) } |
Kojto | 102:da0ca467f8b5 | 167 | .debug_line 0 : { *(.debug_line) } |
Kojto | 102:da0ca467f8b5 | 168 | .debug_frame 0 : { *(.debug_frame) } |
Kojto | 102:da0ca467f8b5 | 169 | .debug_str 0 : { *(.debug_str) } |
Kojto | 102:da0ca467f8b5 | 170 | .debug_loc 0 : { *(.debug_loc) } |
Kojto | 102:da0ca467f8b5 | 171 | .debug_macinfo 0 : { *(.debug_macinfo) } |
Kojto | 102:da0ca467f8b5 | 172 | /* SGI/MIPS DWARF 2 extensions */ |
Kojto | 102:da0ca467f8b5 | 173 | .debug_weaknames 0 : { *(.debug_weaknames) } |
Kojto | 102:da0ca467f8b5 | 174 | .debug_funcnames 0 : { *(.debug_funcnames) } |
Kojto | 102:da0ca467f8b5 | 175 | .debug_typenames 0 : { *(.debug_typenames) } |
Kojto | 102:da0ca467f8b5 | 176 | .debug_varnames 0 : { *(.debug_varnames) } |
Kojto | 102:da0ca467f8b5 | 177 | /* DWARF 3 */ |
Kojto | 102:da0ca467f8b5 | 178 | .debug_pubtypes 0 : { *(.debug_pubtypes) } |
Kojto | 102:da0ca467f8b5 | 179 | .debug_ranges 0 : { *(.debug_ranges) } |
Kojto | 102:da0ca467f8b5 | 180 | |
Kojto | 102:da0ca467f8b5 | 181 | .note.gnu.arm.ident 0 : { KEEP( *( .note.gnu.arm.ident ) ) } |
Kojto | 102:da0ca467f8b5 | 182 | .ARM.attributes 0 : { |
Kojto | 102:da0ca467f8b5 | 183 | KEEP( *( .ARM.attributes ) ) |
Kojto | 102:da0ca467f8b5 | 184 | KEEP( *( .gnu.attributes ) ) |
Kojto | 102:da0ca467f8b5 | 185 | } |
Kojto | 102:da0ca467f8b5 | 186 | /DISCARD/ : { *( .note.GNU-stack ) } |
Kojto | 102:da0ca467f8b5 | 187 | |
Kojto | 102:da0ca467f8b5 | 188 | /* C data can be defined as being in special purpose RAMs using |
Kojto | 102:da0ca467f8b5 | 189 | * __attribute__ ((section ("ethram"))) for example. */ |
Kojto | 102:da0ca467f8b5 | 190 | .usbram (NOLOAD): |
Kojto | 102:da0ca467f8b5 | 191 | { |
Kojto | 102:da0ca467f8b5 | 192 | *( .usbram ) |
Kojto | 102:da0ca467f8b5 | 193 | *( .usbram.* ) |
Kojto | 102:da0ca467f8b5 | 194 | } > UsbRam |
Kojto | 102:da0ca467f8b5 | 195 | .ethram (NOLOAD): |
Kojto | 102:da0ca467f8b5 | 196 | { |
Kojto | 102:da0ca467f8b5 | 197 | *( .ethram ) |
Kojto | 102:da0ca467f8b5 | 198 | *( .ethram.* ) |
Kojto | 102:da0ca467f8b5 | 199 | } > EthRam |
Kojto | 102:da0ca467f8b5 | 200 | .canram (NOLOAD): |
Kojto | 102:da0ca467f8b5 | 201 | { |
Kojto | 102:da0ca467f8b5 | 202 | *( .canram ) |
Kojto | 102:da0ca467f8b5 | 203 | *( .canram.* ) |
Kojto | 102:da0ca467f8b5 | 204 | } > CanRam |
Kojto | 102:da0ca467f8b5 | 205 | .batram (NOLOAD): |
Kojto | 102:da0ca467f8b5 | 206 | { |
Kojto | 102:da0ca467f8b5 | 207 | *( .batram ) |
Kojto | 102:da0ca467f8b5 | 208 | *( .batram.* ) |
Kojto | 102:da0ca467f8b5 | 209 | } > BatRam |
Kojto | 102:da0ca467f8b5 | 210 | } |