in 'MEMORY' section:
MEMORY { ROMEM (rx) : ORIGIN = 0x0000C000, LENGTH = 976K RWMEM (rwx) : ORIGIN = 0x10000000, LENGTH = 383K NOINIT (rwx) :ORIGIN = 0x1005FC00, LENGTH = 1k }
and the following in 'SECTIONS':
.noinit(NOLOAD) : { *(.noinit*) } > NOINIT
Variable:
uint8_t rst_cnt __attribute__ ((section (".noinit")));
it was indeed located (according to map file) as expected: .noinit 0x000000001005fc00 0x1 (.noinit) .noinit 0x000000001005fc00 0x1 bin/example.o 0x000000001005fc00 rst_cnt