/* ROM at 0x08000000, data and bss in IWRAM below the BIOS's area at 0x03007E00. * EWRAM is left to shim.c's console buffer. */ OUTPUT_ARCH(arm) ENTRY(_start) MEMORY { rom : ORIGIN = 0x08000000, LENGTH = 32M iwram : ORIGIN = 0x03000000, LENGTH = 0x7E00 } 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); .bss (NOLOAD) : { __bss_start = .; *(.bss .bss.* COMMON) . = ALIGN(4); __bss_end = .; } > iwram /DISCARD/ : { *(.ARM.exidx*) *(.comment) } }