diff --git a/targets/TARGET_NUVOTON/TARGET_M480/device/TOOLCHAIN_IAR/M487.icf b/targets/TARGET_NUVOTON/TARGET_M480/device/TOOLCHAIN_IAR/M487.icf index 3efed8ee84..3608845ad3 100644 --- a/targets/TARGET_NUVOTON/TARGET_M480/device/TOOLCHAIN_IAR/M487.icf +++ b/targets/TARGET_NUVOTON/TARGET_M480/device/TOOLCHAIN_IAR/M487.icf @@ -9,11 +9,12 @@ define symbol __ICFEDIT_intvec_start__ = MBED_APP_START; /*-Memory Regions-*/ define symbol __ICFEDIT_region_ROM_start__ = MBED_APP_START; define symbol __ICFEDIT_region_ROM_end__ = MBED_APP_START + MBED_APP_SIZE - 1; -define symbol __ICFEDIT_region_IRAM_start__ = 0x20000000; +define symbol __region_CRASH_DATA_RAM_start__ = 0x20000000; +define symbol __region_CRASH_DATA_RAM_end__ = 0x200000FF; +define symbol __ICFEDIT_region_IRAM_start__ = 0x20000100; define symbol __ICFEDIT_region_IRAM_end__ = 0x20028000 - 1; /*-Sizes-*/ define symbol __ICFEDIT_size_cstack__ = MBED_BOOT_STACK_SIZE; -define symbol __ICFEDIT_size_crash_data__ = 0x100; define symbol __ICFEDIT_size_intvec__ = (4 * (16 + 96)); define symbol __ICFEDIT_size_heap__ = 0x10000; /**** End of ICF editor section. ###ICF###*/ @@ -22,16 +23,16 @@ define symbol __ICFEDIT_size_heap__ = 0x10000; define memory mem with size = 4G; define region ROM_region = mem:[from __ICFEDIT_region_ROM_start__ to __ICFEDIT_region_ROM_end__]; define region IRAM_region = mem:[from __ICFEDIT_region_IRAM_start__ to __ICFEDIT_region_IRAM_end__]; +define region CRASH_DATA_RAM_region = mem:[from __region_CRASH_DATA_RAM_start__ to __region_CRASH_DATA_RAM_end__]; define block CSTACK with alignment = 8, size = __ICFEDIT_size_cstack__ { }; define block HEAP with alignment = 8, size = __ICFEDIT_size_heap__ { }; /* NOTE: Vector table base requires to be aligned to the power of vector table size. Give a safe value here. */ define block IRAMVEC with alignment = 1024, size = __ICFEDIT_size_intvec__ { }; -define block CRASH_DATA_RAM with alignment = 8, size = __ICFEDIT_size_crash_data__ { }; /* Define Crash Data Symbols */ -define exported symbol __CRASH_DATA_RAM_START__ = __ICFEDIT_region_IRAM_start__ + __ICFEDIT_size_cstack__ + __ICFEDIT_size_intvec__; -define exported symbol __CRASH_DATA_RAM_END__ = __ICFEDIT_region_IRAM_start__ + __ICFEDIT_size_cstack__ + __ICFEDIT_size_intvec__ + __ICFEDIT_size_crash_data__; +define exported symbol __CRASH_DATA_RAM_START__ = __region_CRASH_DATA_RAM_start__; +define exported symbol __CRASH_DATA_RAM_END__ = __region_CRASH_DATA_RAM_end__; initialize by copy { readwrite }; do not initialize { section .noinit }; @@ -41,6 +42,5 @@ place at address mem:__ICFEDIT_intvec_start__ { readonly section .intvec }; place in ROM_region { readonly }; place at start of IRAM_region { block CSTACK }; place in IRAM_region { block IRAMVEC }; -place in IRAM_region { block CRASH_DATA_RAM }; place in IRAM_region { readwrite }; place in IRAM_region { block HEAP }; \ No newline at end of file