/* * A whole-chip image for the PIC32MZ2048EC/EF (2 MB flash, 512 KB RAM): reset code at the * reset vector in the lower boot alias, the configuration words at 0xBFC0FFC0 (DS60001320H * Table 4-x: DEVCFG3 lowest), the exception base at the start of program flash. */ MEMORY { boot (rx) : ORIGIN = 0xBFC00000, LENGTH = 0xFFC0 config : ORIGIN = 0xBFC0FFC0, LENGTH = 0x10 flash (rx) : ORIGIN = 0x9D000000, LENGTH = 0x200000 ram (rwx) : ORIGIN = 0x80000000, LENGTH = 0x80000 } ENTRY(_reset) SECTIONS { .reset : { KEEP(*(.reset)) } > boot .config : { KEEP(*(.config)) } > config .vectors : { KEEP(*(.vectors)) } > flash .text : { *(.text*) *(.rodata*) } > flash .data : { _data = .; *(.data*) *(.sdata*) . = ALIGN(4); _edata = .; } > ram AT> flash _data_load = LOADADDR(.data); .bss (NOLOAD) : { _bss = .; *(.bss*) *(.sbss*) *(COMMON) . = ALIGN(4); _ebss = .; } > ram _stack = ORIGIN(ram) + LENGTH(ram) - 16; /DISCARD/ : { *(.MIPS.abiflags) *(.reginfo) *(.comment) *(.pdr) *(.gnu.attributes) } }