1
+ include partition_M2351_sub
2
+
1
3
/*###ICF### Section handled by ICF editor, don't touch! ****/
2
4
/*-Editor annotation file-*/
3
5
/* IcfEditorFile="$TOOLKIT_DIR$\config\ide\IcfEditor\cortex_v1_0.xml" */
4
6
5
7
if (isdefinedsymbol(__DOMAIN_NS)) {
6
- /*-Specials-*/
7
- define symbol __ICFEDIT_intvec_start__ = 0x10040000;
8
- /*-Memory Regions-*/
9
- define symbol __ICFEDIT_region_ROM_start__ = 0x10040000;
10
- define symbol __ICFEDIT_region_ROM_end__ = 0x10080000 - 1;
11
- define symbol __ICFEDIT_region_IRAM_start__ = 0x30006000;
12
- define symbol __ICFEDIT_region_IRAM_end__ = 0x30018000 - 1 ;
13
- } else {
14
- /*-Specials-*/
15
- define symbol __ICFEDIT_intvec_start__ = 0x00000000;
16
- /*-Memory Regions -*/
17
- define symbol __ICFEDIT_region_ROM_start__ = 0x00000000 ;
18
- define symbol __ICFEDIT_region_ROM_end__ = 0x0003F000 - 1;
19
- define symbol __ICFEDIT_region_NSCROM_start__ = 0x0003F000 ;
20
- define symbol __ICFEDIT_region_NSCROM_end__ = 0x00040000 - 1;
21
- define symbol __ICFEDIT_region_IRAM_start__ = 0x20000000 ;
22
- define symbol __ICFEDIT_region_IRAM_end__ = 0x20006000 - 1;
23
- }
24
- /*-Sizes-*/
25
- define symbol __ICFEDIT_size_cstack__ = 0x800;
26
- if (isdefinedsymbol(__DOMAIN_NS)) {
27
- define symbol __ICFEDIT_size_heap__ = 0x4000;
8
+
9
+ if (! isdefinedsymbol(MBED_APP_START)) {
10
+ define symbol MBED_APP_START = 0x10000000 + NU_TZ_SECURE_FLASH_SIZE;
11
+ }
12
+
13
+ if (! isdefinedsymbol(MBED_APP_SIZE)) {
14
+ define symbol MBED_APP_SIZE = 0x80000 - NU_TZ_SECURE_FLASH_SIZE ;
15
+ }
16
+
17
+
18
+ /*-Specials -*/
19
+ define symbol __ICFEDIT_intvec_start__ = MBED_APP_START ;
20
+ /*-Memory Regions-*/
21
+ define symbol __ICFEDIT_region_ROM_start__ = MBED_APP_START ;
22
+ define symbol __ICFEDIT_region_ROM_end__ = MBED_APP_START + MBED_APP_SIZE - 1;
23
+ define symbol __ICFEDIT_region_IRAM_start__ = 0x30000000 + NU_TZ_SECURE_SRAM_SIZE ;
24
+ define symbol __ICFEDIT_region_IRAM_end__ = 0x30018000 - 1;
25
+
26
+ /*-Sizes-*/
27
+ define symbol __ICFEDIT_size_cstack__ = 0x800;
28
+ define symbol __ICFEDIT_size_heap__ = 0x4000;
29
+
28
30
} else {
29
- define symbol __ICFEDIT_size_heap__ = 0x1000;
31
+
32
+ if (! isdefinedsymbol(MBED_APP_START)) {
33
+ define symbol MBED_APP_START = 0;
34
+ }
35
+
36
+ if (! isdefinedsymbol(MBED_APP_SIZE)) {
37
+ define symbol MBED_APP_SIZE = NU_TZ_SECURE_FLASH_SIZE;
38
+ }
39
+
40
+ /* Requirements for NSC location
41
+ *
42
+ * 1. By IDAU, 0~0x4000 is secure. NSC can only locate in 0x4000~0x10000000.
43
+ * 2. Greentea flash IAP uses last 4 sectors for its test. Avoid this range.
44
+ * 3. Greentea NVSTORE uses last 2 sectors or 4KB x 2 for its test. Avoid this range.
45
+ */
46
+ define exported symbol NU_TZ_NSC_REGION_BASE = MBED_APP_START + MBED_APP_SIZE - 0x2000 - NU_TZ_NSC_REGION_SIZE;
47
+
48
+ /*-Specials-*/
49
+ define symbol __ICFEDIT_intvec_start__ = MBED_APP_START;
50
+ /*-Memory Regions-*/
51
+ define symbol __ICFEDIT_region_ROM_start__ = MBED_APP_START;
52
+ define symbol __ICFEDIT_region_ROM_end__ = MBED_APP_START + MBED_APP_SIZE - 1;
53
+ define symbol __ICFEDIT_region_NSCROM_start__ = NU_TZ_NSC_REGION_BASE;
54
+ define symbol __ICFEDIT_region_NSCROM_end__ = NU_TZ_NSC_REGION_BASE + NU_TZ_NSC_REGION_SIZE - 1;
55
+ define symbol __ICFEDIT_region_IRAM_start__ = 0x20000000;
56
+ define symbol __ICFEDIT_region_IRAM_end__ = 0x20000000 + NU_TZ_SECURE_SRAM_SIZE - 1;
57
+
58
+ export symbol __NU_TZ_SECURE_FLASH_SIZE__ = NU_TZ_SECURE_FLASH_SIZE;
59
+ export symbol __NU_TZ_SECURE_SRAM_SIZE__ = NU_TZ_SECURE_SRAM_SIZE;
60
+ export symbol __NU_TZ_NSC_REGION_BASE__ = NU_TZ_NSC_REGION_BASE;
61
+ export symbol __NU_TZ_NSC_REGION_SIZE__ = NU_TZ_NSC_REGION_SIZE;
62
+
63
+ /*-Sizes-*/
64
+ define symbol __ICFEDIT_size_cstack__ = 0x800;
65
+ define symbol __ICFEDIT_size_heap__ = 0x1000;
30
66
}
67
+
31
68
/**** End of ICF editor section. ###ICF###*/
32
69
33
70
@@ -47,10 +84,10 @@ do not initialize { section .noinit };
47
84
place at address mem:__ICFEDIT_intvec_start__ { readonly section .intvec };
48
85
49
86
place in ROM_region { readonly };
50
- if (!isdefinedsymbol(__DOMAIN_NS)) {
51
- place at address mem:__ICFEDIT_region_NSCROM_start__ { readonly section Veneer$$CMSE };
87
+ if (! isdefinedsymbol(__DOMAIN_NS)) {
88
+ place at address mem:__ICFEDIT_region_NSCROM_start__ { readonly section Veneer$$CMSE };
52
89
}
53
90
place at start of IRAM_region { block CSTACK };
54
91
place in IRAM_region { block IRAMVEC };
55
92
place in IRAM_region { readwrite };
56
- place in IRAM_region { block HEAP };
93
+ place in IRAM_region { block HEAP };
0 commit comments