/* ROM at 0x08000000. Probe copies in IWRAM (below the BIOS's area at * 0x03007E00: stacks, IRQ vector) and in EWRAM; both load from ROM. */ OUTPUT_ARCH(arm) ENTRY(_start) MEMORY { rom : ORIGIN = 0x08000000, LENGTH = 32M iwram : ORIGIN = 0x03000000, LENGTH = 0x7E00 ewram : ORIGIN = 0x02000000, LENGTH = 256K } SECTIONS { .text : { KEEP(*(.header)) *(.text .text.*) *(.rodata .rodata.*) . = ALIGN(4); } > rom .iwram : { __iwram_start = .; *(.iwram .iwram.*) *(.data .data.*) . = ALIGN(4); __iwram_end = .; } > iwram AT > rom __iwram_lma = LOADADDR(.iwram); .ewram : { __ewram_start = .; *(.ewram .ewram.*) . = ALIGN(4); __ewram_end = .; } > ewram AT > rom __ewram_lma = LOADADDR(.ewram); .bss (NOLOAD) : { __bss_start = .; *(.bss .bss.* COMMON) . = ALIGN(4); __bss_end = .; } > iwram /DISCARD/ : { *(.ARM.exidx*) *(.comment) } }