-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathmemory.x
More file actions
31 lines (25 loc) · 669 Bytes
/
memory.x
File metadata and controls
31 lines (25 loc) · 669 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
MEMORY {
BOOT2 : ORIGIN = 0x10000000, LENGTH = 0x100
FLASH : ORIGIN = 0x10000100, LENGTH = 2048K - 0x100
RAM : ORIGIN = 0x20000000, LENGTH = 256K
XIP_RAM : ORIGIN = 0x15000000, LENGTH = 16K
}
EXTERN(BOOT2_FIRMWARE)
SECTIONS {
/* ### Boot loader */
.boot2 ORIGIN(BOOT2) :
{
KEEP(*(.boot2));
} > BOOT2
} INSERT BEFORE .text;
SECTIONS {
/* ### to be copied to XIP_RAM on demand */
.xiptext ORIGIN(XIP_RAM) : {
. = ALIGN(4);
__sxiptext = .;
KEEP(*(.xiptext .xiptext.*));
. = ALIGN(4);
__exiptext = .;
} > RAM AT > FLASH
__sixiptext = LOADADDR(.xiptext);
} INSERT AFTER .rodata;