From 5187d75af538d9ae268e7d4d31dd412f20d0a63d Mon Sep 17 00:00:00 2001 From: Meco Man <920369182@qq.com> Date: Wed, 29 Dec 2021 14:14:07 -0500 Subject: [PATCH 1/2] =?UTF-8?q?[armclang]=20=E4=BD=BF=E7=94=A8=5F=5Fclang?= =?UTF-8?q?=5F=5F=E4=BB=A3=E6=9B=BF=5F=5FCLANG=5FARM?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bsp/Vango_V85xx/drivers/board.h | 2 +- bsp/acm32f0x0-nucleo/drivers/board.c | 4 ++-- bsp/acm32f4xx-nucleo/drivers/board.c | 4 ++-- bsp/apm32/apm32f103xe-minibroard/board/board.h | 2 +- bsp/at32/at32f403a-start/board/board.h | 2 +- bsp/at32/at32f407-start/board/board.h | 2 +- bsp/essemi/es32f0654/drivers/board.h | 2 +- bsp/essemi/es32f365x/drivers/board.h | 2 +- bsp/essemi/es32f369x/drivers/board.h | 2 +- bsp/gd32e230k-start/drivers/board.h | 2 +- bsp/hk32/hk32f030c8-mini/board/board.h | 2 +- .../Libraries/template/lpc55s6xxxx/applications/main.c | 2 +- bsp/lpc55sxx/Libraries/template/lpc55s6xxxx/board/board.h | 2 +- bsp/lpc55sxx/lpc55s69_nxp_evk/applications/main.c | 2 +- bsp/lpc55sxx/lpc55s69_nxp_evk/board/board.h | 2 +- bsp/maxim/MAX32660_EVSYS/board/board.h | 2 +- bsp/mm32l07x/drivers/board.h | 2 +- bsp/n32g452xx/n32g452xx-mini-system/board/board.h | 2 +- bsp/nrf5x/libraries/templates/nrfx/board/board.h | 2 +- bsp/nrf5x/nrf51822/board/board.h | 2 +- bsp/nrf5x/nrf52832/board/board.h | 2 +- bsp/nrf5x/nrf52833/board/board.h | 2 +- bsp/nrf5x/nrf52840/board/board.h | 2 +- bsp/nuvoton/numaker-iot-m487/board/board.h | 2 +- bsp/nuvoton/numaker-m032ki/board/board.h | 2 +- bsp/nuvoton/numaker-m2354/board/board.h | 2 +- bsp/nuvoton/numaker-pfm-m487/board/board.h | 2 +- bsp/samd21/applications/startup.c | 4 ++-- bsp/stm32/libraries/templates/stm32f0xx/board/board.h | 2 +- bsp/stm32/libraries/templates/stm32f10x/board/board.h | 2 +- bsp/stm32/libraries/templates/stm32f2xx/board/board.h | 2 +- bsp/stm32/libraries/templates/stm32f3xx/board/board.h | 2 +- bsp/stm32/libraries/templates/stm32f4xx/board/board.h | 2 +- bsp/stm32/libraries/templates/stm32f7xx/board/board.h | 2 +- bsp/stm32/libraries/templates/stm32h7xx/board/board.h | 2 +- bsp/stm32/libraries/templates/stm32l1xx/board/board.h | 2 +- bsp/stm32/libraries/templates/stm32l4xx/board/board.h | 2 +- bsp/stm32/libraries/templates/stm32l5xx/board/board.h | 2 +- bsp/stm32/libraries/templates/stm32mp1xx/board/board.h | 2 +- bsp/stm32/libraries/templates/stm32wbxx/board/board.h | 2 +- bsp/stm32/stm32f072-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32f091-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32f103-atk-nano/board/board.h | 2 +- bsp/stm32/stm32f103-atk-warshipv3/board/board.h | 2 +- bsp/stm32/stm32f103-blue-pill/board/board.h | 2 +- bsp/stm32/stm32f103-dofly-M3S/board/board.h | 2 +- bsp/stm32/stm32f103-dofly-lyc8/board/board.h | 2 +- bsp/stm32/stm32f103-fire-arbitrary/board/board.h | 2 +- bsp/stm32/stm32f103-gizwits-gokitv21/board/board.h | 2 +- bsp/stm32/stm32f103-hw100k-ibox/board/board.h | 2 +- bsp/stm32/stm32f103-onenet-nbiot/board/board.h | 2 +- bsp/stm32/stm32f103-yf-ufun/board/board.h | 2 +- bsp/stm32/stm32f107-uc-eval/board/board.h | 2 +- bsp/stm32/stm32f207-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32f302-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32f401-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32f405-smdz-breadfruit/board/board.h | 2 +- bsp/stm32/stm32f407-armfly-v5/board/board.h | 2 +- .../stm32f407-atk-explorer/applications/lvgl/lv_port_disp.c | 2 +- bsp/stm32/stm32f407-atk-explorer/board/board.h | 2 +- bsp/stm32/stm32f407-robomaster-c/board/board.h | 2 +- bsp/stm32/stm32f407-st-discovery/board/board.h | 2 +- bsp/stm32/stm32f410-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32f411-atk-nano/board/board.h | 2 +- bsp/stm32/stm32f411-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32f411-weact-MiniF4/board/board.h | 2 +- bsp/stm32/stm32f412-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32f413-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32f427-robomaster-a/board/board.h | 2 +- bsp/stm32/stm32f429-armfly-v6/board/board.h | 2 +- bsp/stm32/stm32f429-atk-apollo/board/board.h | 2 +- bsp/stm32/stm32f429-fire-challenger/board/board.h | 2 +- bsp/stm32/stm32f429-st-disco/board/board.h | 2 +- bsp/stm32/stm32f446-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32f469-st-disco/board/board.h | 2 +- bsp/stm32/stm32f746-st-disco/board/board.h | 2 +- bsp/stm32/stm32f746-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32f767-atk-apollo/board/board.h | 2 +- bsp/stm32/stm32f767-fire-challenger-v1/board/board.h | 2 +- bsp/stm32/stm32f767-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32f769-st-disco/board/board.h | 2 +- bsp/stm32/stm32g070-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32g071-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32g431-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32g474-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32h743-armfly-V7/board/board.h | 2 +- bsp/stm32/stm32h743-atk-apollo/board/board.h | 2 +- bsp/stm32/stm32h743-openmv-h7plus/board/board.h | 2 +- bsp/stm32/stm32h743-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32h747-st-discovery/board/board.h | 2 +- bsp/stm32/stm32h750-armfly-h7-tool/board/board.h | 2 +- bsp/stm32/stm32h750-artpi-h750/board/board.h | 2 +- bsp/stm32/stm32l010-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32l053-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32l433-ali-startkit/board/board.h | 2 +- bsp/stm32/stm32l452-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32l475-atk-pandora/board/board.h | 2 +- bsp/stm32/stm32l496-ali-developer/board/board.h | 2 +- bsp/stm32/stm32l496-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32l4r9-st-sensortile-box/board/board.h | 2 +- bsp/stm32/stm32l552-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32mp157a-st-discovery/board/board.h | 2 +- .../stm32mp157a-st-discovery/board/ports/audio/drv_mic.c | 2 +- .../stm32mp157a-st-discovery/board/ports/audio/drv_sound.c | 2 +- bsp/stm32/stm32mp157a-st-discovery/board/ports/drv_eth.c | 2 +- bsp/stm32/stm32mp157a-st-discovery/board/ports/drv_sdio.c | 2 +- bsp/stm32/stm32mp157a-st-ev1/board/board.h | 2 +- bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_dfsdm.c | 6 +++--- bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_emmc.c | 2 +- bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_ov5640.c | 4 ++-- bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_sdcard.c | 2 +- bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_sound.c | 2 +- bsp/stm32/stm32mp157a-st-ev1/board/ports/eth/drv_eth.c | 2 +- bsp/stm32/stm32u575-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32wb55-st-nucleo/board/board.h | 2 +- bsp/swm320-lq100/drivers/board.h | 2 +- bsp/swm320/drivers/board.h | 2 +- bsp/tm4c123bsp/board/board.h | 2 +- bsp/wch/arm/ch32f103c8-core/board/board.h | 2 +- bsp/yichip/yc3121-pos/drivers/board.h | 2 +- components/cplusplus/cxx_crt_init.c | 4 ++-- components/libc/compilers/armlibc/syscalls.c | 4 ++-- components/utilities/utest/utest.c | 2 +- components/utilities/var_export/var_export.c | 6 +++--- include/rtdef.h | 4 ---- libcpu/arm/cortex-m3/cpuport.c | 2 +- libcpu/arm/cortex-m33/cpuport.c | 4 ++-- libcpu/arm/cortex-m33/trustzone.c | 2 +- libcpu/arm/cortex-m4/cpuport.c | 4 ++-- libcpu/arm/cortex-m7/cpuport.c | 4 ++-- libcpu/sim/win32/startup.c | 4 ++-- 131 files changed, 144 insertions(+), 148 deletions(-) diff --git a/bsp/Vango_V85xx/drivers/board.h b/bsp/Vango_V85xx/drivers/board.h index e8e312d110..837f195b9e 100644 --- a/bsp/Vango_V85xx/drivers/board.h +++ b/bsp/Vango_V85xx/drivers/board.h @@ -21,7 +21,7 @@ #define V85XX_SRAM_SIZE 32 #define V85XX_SRAM_END (0x20000000 + V85XX_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/acm32f0x0-nucleo/drivers/board.c b/bsp/acm32f0x0-nucleo/drivers/board.c index 28e8b77322..841560184e 100644 --- a/bsp/acm32f0x0-nucleo/drivers/board.c +++ b/bsp/acm32f0x0-nucleo/drivers/board.c @@ -18,7 +18,7 @@ extern int rt_application_init(void); -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #elif __ICCARM__ #pragma section="HEAP" @@ -58,7 +58,7 @@ void rt_hw_board_init(void) rt_console_set_device(RT_CONSOLE_DEVICE_NAME); #ifdef RT_USING_HEAP -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) rt_system_heap_init((void *)&Image$$RW_IRAM1$$ZI$$Limit, (void *)SOC_SRAM_END_ADDR); #elif __ICCARM__ rt_system_heap_init(__segment_end("HEAP"), (void *)SOC_SRAM_END_ADDR); diff --git a/bsp/acm32f4xx-nucleo/drivers/board.c b/bsp/acm32f4xx-nucleo/drivers/board.c index 050db7656b..202a0371da 100644 --- a/bsp/acm32f4xx-nucleo/drivers/board.c +++ b/bsp/acm32f4xx-nucleo/drivers/board.c @@ -17,7 +17,7 @@ extern int rt_application_init(void); -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #elif __ICCARM__ #pragma section="HEAP" @@ -57,7 +57,7 @@ void rt_hw_board_init(void) rt_console_set_device(RT_CONSOLE_DEVICE_NAME); #ifdef RT_USING_HEAP -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) rt_system_heap_init((void *)&Image$$RW_IRAM1$$ZI$$Limit, (void *)SOC_SRAM_END_ADDR); #elif __ICCARM__ rt_system_heap_init(__segment_end("HEAP"), (void *)SOC_SRAM_END_ADDR); diff --git a/bsp/apm32/apm32f103xe-minibroard/board/board.h b/bsp/apm32/apm32f103xe-minibroard/board/board.h index da63a21995..b2f4773b26 100644 --- a/bsp/apm32/apm32f103xe-minibroard/board/board.h +++ b/bsp/apm32/apm32f103xe-minibroard/board/board.h @@ -36,7 +36,7 @@ extern "C" { #define APM32_SRAM_SIZE 128 #define APM32_SRAM_END (0x20000000 + APM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/at32/at32f403a-start/board/board.h b/bsp/at32/at32f403a-start/board/board.h index 1f2a4f3f3c..762b087a7c 100644 --- a/bsp/at32/at32f403a-start/board/board.h +++ b/bsp/at32/at32f403a-start/board/board.h @@ -29,7 +29,7 @@ extern "C" { #define AT32_SRAM_SIZE 96 #define AT32_SRAM_END (0x20000000 + AT32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/at32/at32f407-start/board/board.h b/bsp/at32/at32f407-start/board/board.h index 1f2a4f3f3c..762b087a7c 100644 --- a/bsp/at32/at32f407-start/board/board.h +++ b/bsp/at32/at32f407-start/board/board.h @@ -29,7 +29,7 @@ extern "C" { #define AT32_SRAM_SIZE 96 #define AT32_SRAM_END (0x20000000 + AT32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/essemi/es32f0654/drivers/board.h b/bsp/essemi/es32f0654/drivers/board.h index 73ca6c11de..c187b82b24 100644 --- a/bsp/essemi/es32f0654/drivers/board.h +++ b/bsp/essemi/es32f0654/drivers/board.h @@ -31,7 +31,7 @@ #define ES32F0_SRAM_SIZE 0x8000 #define ES32F0_SRAM_END (0x20000000 + ES32F0_SRAM_SIZE) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/essemi/es32f365x/drivers/board.h b/bsp/essemi/es32f365x/drivers/board.h index 796121513a..34ee8b1c38 100644 --- a/bsp/essemi/es32f365x/drivers/board.h +++ b/bsp/essemi/es32f365x/drivers/board.h @@ -30,7 +30,7 @@ #define ES32F3_SRAM_SIZE 0x10000 #define ES32F3_SRAM_END (0x20000000 + ES32F3_SRAM_SIZE) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/essemi/es32f369x/drivers/board.h b/bsp/essemi/es32f369x/drivers/board.h index 971216e9a9..871ab7436e 100644 --- a/bsp/essemi/es32f369x/drivers/board.h +++ b/bsp/essemi/es32f369x/drivers/board.h @@ -31,7 +31,7 @@ #define ES32F3_SRAM_SIZE 0x18000 #define ES32F3_SRAM_END (0x20000000 + ES32F3_SRAM_SIZE) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/gd32e230k-start/drivers/board.h b/bsp/gd32e230k-start/drivers/board.h index 7d491aeaa8..c76f570768 100644 --- a/bsp/gd32e230k-start/drivers/board.h +++ b/bsp/gd32e230k-start/drivers/board.h @@ -25,7 +25,7 @@ extern char __ICFEDIT_region_RAM_end__; #define GD32_SRAM_END (0x20000000 + GD32_SRAM_SIZE * 1024) #endif -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/hk32/hk32f030c8-mini/board/board.h b/bsp/hk32/hk32f030c8-mini/board/board.h index 6e6d0d4f5c..b0b3752ee1 100644 --- a/bsp/hk32/hk32f030c8-mini/board/board.h +++ b/bsp/hk32/hk32f030c8-mini/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define HK32_SRAM_SIZE 10 #define HK32_SRAM_END (0x20000000 + HK32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/lpc55sxx/Libraries/template/lpc55s6xxxx/applications/main.c b/bsp/lpc55sxx/Libraries/template/lpc55s6xxxx/applications/main.c index ef4393ba39..d9a8b55a1b 100644 --- a/bsp/lpc55sxx/Libraries/template/lpc55s6xxxx/applications/main.c +++ b/bsp/lpc55sxx/Libraries/template/lpc55s6xxxx/applications/main.c @@ -20,7 +20,7 @@ int main(void) { #if defined(__CC_ARM) rt_kprintf("using armcc, version: %d\n", __ARMCC_VERSION); -#elif defined(__CLANG_ARM) +#elif defined(__clang__) rt_kprintf("using armclang, version: %d\n", __ARMCC_VERSION); #elif defined(__ICCARM__) rt_kprintf("using iccarm, version: %d\n", __VER__); diff --git a/bsp/lpc55sxx/Libraries/template/lpc55s6xxxx/board/board.h b/bsp/lpc55sxx/Libraries/template/lpc55s6xxxx/board/board.h index 1899798c13..20c46767d1 100644 --- a/bsp/lpc55sxx/Libraries/template/lpc55s6xxxx/board/board.h +++ b/bsp/lpc55sxx/Libraries/template/lpc55s6xxxx/board/board.h @@ -29,7 +29,7 @@ // // -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$ARM_LIB_HEAP$$ZI$$Base; #define HEAP_BEGIN ((void *)&Image$$ARM_LIB_HEAP$$ZI$$Base) #elif defined(__ICCARM__) diff --git a/bsp/lpc55sxx/lpc55s69_nxp_evk/applications/main.c b/bsp/lpc55sxx/lpc55s69_nxp_evk/applications/main.c index 7a368dcd54..3dd5d599dc 100644 --- a/bsp/lpc55sxx/lpc55s69_nxp_evk/applications/main.c +++ b/bsp/lpc55sxx/lpc55s69_nxp_evk/applications/main.c @@ -24,7 +24,7 @@ int main(void) { #if defined(__CC_ARM) rt_kprintf("using armcc, version: %d\n", __ARMCC_VERSION); -#elif defined(__CLANG_ARM) +#elif defined(__clang__) rt_kprintf("using armclang, version: %d\n", __ARMCC_VERSION); #elif defined(__ICCARM__) rt_kprintf("using iccarm, version: %d\n", __VER__); diff --git a/bsp/lpc55sxx/lpc55s69_nxp_evk/board/board.h b/bsp/lpc55sxx/lpc55s69_nxp_evk/board/board.h index 7500557fcb..bdda20fbb4 100644 --- a/bsp/lpc55sxx/lpc55s69_nxp_evk/board/board.h +++ b/bsp/lpc55sxx/lpc55s69_nxp_evk/board/board.h @@ -29,7 +29,7 @@ // // -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$ARM_LIB_HEAP$$ZI$$Base; extern int Image$$ARM_LIB_STACK$$ZI$$Base; #define HEAP_BEGIN ((void *)&Image$$ARM_LIB_HEAP$$ZI$$Base) diff --git a/bsp/maxim/MAX32660_EVSYS/board/board.h b/bsp/maxim/MAX32660_EVSYS/board/board.h index 490e91a95f..093bb86ad8 100644 --- a/bsp/maxim/MAX32660_EVSYS/board/board.h +++ b/bsp/maxim/MAX32660_EVSYS/board/board.h @@ -26,7 +26,7 @@ #define MCU_SRAM_START (0x20000000) #define MCU_SRAM_END (MCU_SRAM_START + MCU_SRAM_SIZE_KB * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/mm32l07x/drivers/board.h b/bsp/mm32l07x/drivers/board.h index cfc02d288e..fc2da93b0e 100644 --- a/bsp/mm32l07x/drivers/board.h +++ b/bsp/mm32l07x/drivers/board.h @@ -16,7 +16,7 @@ #define SRAM_SIZE 0x2000 #define SRAM_END (SRAM_BASE + SRAM_SIZE) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/n32g452xx/n32g452xx-mini-system/board/board.h b/bsp/n32g452xx/n32g452xx-mini-system/board/board.h index 71f5ca48a0..0a3b0fa661 100644 --- a/bsp/n32g452xx/n32g452xx-mini-system/board/board.h +++ b/bsp/n32g452xx/n32g452xx-mini-system/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define N32_SRAM_SIZE (80) #define N32_SRAM_END (0x20000000 + N32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/nrf5x/libraries/templates/nrfx/board/board.h b/bsp/nrf5x/libraries/templates/nrfx/board/board.h index 52e812fac6..26543f7f6f 100644 --- a/bsp/nrf5x/libraries/templates/nrfx/board/board.h +++ b/bsp/nrf5x/libraries/templates/nrfx/board/board.h @@ -20,7 +20,7 @@ #define MCU_SRAM_SIZE MCU_SRAM_SIZE_KB*1024 #define MCU_SRAM_END_ADDRESS (MCU_SRAM_START_ADDRESS + MCU_SRAM_SIZE) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/nrf5x/nrf51822/board/board.h b/bsp/nrf5x/nrf51822/board/board.h index a3ccadfa36..f2bbf90e79 100644 --- a/bsp/nrf5x/nrf51822/board/board.h +++ b/bsp/nrf5x/nrf51822/board/board.h @@ -10,7 +10,7 @@ #define MCU_SRAM_SIZE MCU_SRAM_SIZE_KB*1024 #define MCU_SRAM_END_ADDRESS (MCU_SRAM_START_ADDRESS + MCU_SRAM_SIZE) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/nrf5x/nrf52832/board/board.h b/bsp/nrf5x/nrf52832/board/board.h index 32acd6b56c..2b556fb6e6 100644 --- a/bsp/nrf5x/nrf52832/board/board.h +++ b/bsp/nrf5x/nrf52832/board/board.h @@ -10,7 +10,7 @@ #define MCU_SRAM_SIZE MCU_SRAM_SIZE_KB*1024 #define MCU_SRAM_END_ADDRESS (MCU_SRAM_START_ADDRESS + MCU_SRAM_SIZE) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/nrf5x/nrf52833/board/board.h b/bsp/nrf5x/nrf52833/board/board.h index 52e812fac6..26543f7f6f 100644 --- a/bsp/nrf5x/nrf52833/board/board.h +++ b/bsp/nrf5x/nrf52833/board/board.h @@ -20,7 +20,7 @@ #define MCU_SRAM_SIZE MCU_SRAM_SIZE_KB*1024 #define MCU_SRAM_END_ADDRESS (MCU_SRAM_START_ADDRESS + MCU_SRAM_SIZE) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/nrf5x/nrf52840/board/board.h b/bsp/nrf5x/nrf52840/board/board.h index edfb0b635a..533a45156e 100644 --- a/bsp/nrf5x/nrf52840/board/board.h +++ b/bsp/nrf5x/nrf52840/board/board.h @@ -20,7 +20,7 @@ #define MCU_SRAM_SIZE MCU_SRAM_SIZE_KB*1024 #define MCU_SRAM_END_ADDRESS (MCU_SRAM_START_ADDRESS + MCU_SRAM_SIZE) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/nuvoton/numaker-iot-m487/board/board.h b/bsp/nuvoton/numaker-iot-m487/board/board.h index cd45f65e76..60515faf35 100644 --- a/bsp/nuvoton/numaker-iot-m487/board/board.h +++ b/bsp/nuvoton/numaker-iot-m487/board/board.h @@ -17,7 +17,7 @@ #define SRAM_SIZE (160) #define SRAM_END (0x20000000 + SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/nuvoton/numaker-m032ki/board/board.h b/bsp/nuvoton/numaker-m032ki/board/board.h index acdd559291..bc6fc79f82 100644 --- a/bsp/nuvoton/numaker-m032ki/board/board.h +++ b/bsp/nuvoton/numaker-m032ki/board/board.h @@ -17,7 +17,7 @@ #define SRAM_SIZE (96) #define SRAM_END (0x20000000 + SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/nuvoton/numaker-m2354/board/board.h b/bsp/nuvoton/numaker-m2354/board/board.h index e783166fef..c28c4ee36a 100644 --- a/bsp/nuvoton/numaker-m2354/board/board.h +++ b/bsp/nuvoton/numaker-m2354/board/board.h @@ -17,7 +17,7 @@ #define SRAM_SIZE (256) #define SRAM_END (0x20000000 + SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/nuvoton/numaker-pfm-m487/board/board.h b/bsp/nuvoton/numaker-pfm-m487/board/board.h index cd45f65e76..60515faf35 100644 --- a/bsp/nuvoton/numaker-pfm-m487/board/board.h +++ b/bsp/nuvoton/numaker-pfm-m487/board/board.h @@ -17,7 +17,7 @@ #define SRAM_SIZE (160) #define SRAM_END (0x20000000 + SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/samd21/applications/startup.c b/bsp/samd21/applications/startup.c index ecbe617d2e..0a689a9e74 100644 --- a/bsp/samd21/applications/startup.c +++ b/bsp/samd21/applications/startup.c @@ -29,7 +29,7 @@ extern void finsh_system_init(void); extern void finsh_set_device(const char* device); #endif -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #elif __ICCARM__ #pragma section="HEAP" @@ -72,7 +72,7 @@ void rtthread_startup(void) rt_system_timer_init(); #ifdef RT_USING_HEAP - #if defined(__CC_ARM) || defined(__CLANG_ARM) + #if defined(__ARMCC_VERSION) rt_system_heap_init((void*)&Image$$RW_IRAM1$$ZI$$Limit, (void*)CHIP_SRAM_END); #elif __ICCARM__ rt_system_heap_init(__segment_end("HEAP"), (void*)CHIP_SRAM_END); diff --git a/bsp/stm32/libraries/templates/stm32f0xx/board/board.h b/bsp/stm32/libraries/templates/stm32f0xx/board/board.h index fbc2af5ebe..557856de37 100644 --- a/bsp/stm32/libraries/templates/stm32f0xx/board/board.h +++ b/bsp/stm32/libraries/templates/stm32f0xx/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 32 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/libraries/templates/stm32f10x/board/board.h b/bsp/stm32/libraries/templates/stm32f10x/board/board.h index fc435ee029..a6aa7d6654 100644 --- a/bsp/stm32/libraries/templates/stm32f10x/board/board.h +++ b/bsp/stm32/libraries/templates/stm32f10x/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 20 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/libraries/templates/stm32f2xx/board/board.h b/bsp/stm32/libraries/templates/stm32f2xx/board/board.h index b93a301f4e..6d0c5e53b6 100644 --- a/bsp/stm32/libraries/templates/stm32f2xx/board/board.h +++ b/bsp/stm32/libraries/templates/stm32f2xx/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 128 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/libraries/templates/stm32f3xx/board/board.h b/bsp/stm32/libraries/templates/stm32f3xx/board/board.h index 1de41e4a63..de61eb7514 100644 --- a/bsp/stm32/libraries/templates/stm32f3xx/board/board.h +++ b/bsp/stm32/libraries/templates/stm32f3xx/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE 16 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/libraries/templates/stm32f4xx/board/board.h b/bsp/stm32/libraries/templates/stm32f4xx/board/board.h index 514155b823..50bf01a1ca 100644 --- a/bsp/stm32/libraries/templates/stm32f4xx/board/board.h +++ b/bsp/stm32/libraries/templates/stm32f4xx/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE 128 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/libraries/templates/stm32f7xx/board/board.h b/bsp/stm32/libraries/templates/stm32f7xx/board/board.h index 2951235675..a02fbca511 100644 --- a/bsp/stm32/libraries/templates/stm32f7xx/board/board.h +++ b/bsp/stm32/libraries/templates/stm32f7xx/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE (512) #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/libraries/templates/stm32h7xx/board/board.h b/bsp/stm32/libraries/templates/stm32h7xx/board/board.h index 72d84ff29d..9c856893de 100644 --- a/bsp/stm32/libraries/templates/stm32h7xx/board/board.h +++ b/bsp/stm32/libraries/templates/stm32h7xx/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE (512) #define STM32_SRAM_END (0x24000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/libraries/templates/stm32l1xx/board/board.h b/bsp/stm32/libraries/templates/stm32l1xx/board/board.h index f6cfb3522b..01696fe3c5 100644 --- a/bsp/stm32/libraries/templates/stm32l1xx/board/board.h +++ b/bsp/stm32/libraries/templates/stm32l1xx/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE 16 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/libraries/templates/stm32l4xx/board/board.h b/bsp/stm32/libraries/templates/stm32l4xx/board/board.h index b5120ac476..a2555c2b6f 100644 --- a/bsp/stm32/libraries/templates/stm32l4xx/board/board.h +++ b/bsp/stm32/libraries/templates/stm32l4xx/board/board.h @@ -29,7 +29,7 @@ extern "C" { #define STM32_SRAM1_START (0x20000000) #define STM32_SRAM1_END (STM32_SRAM1_START + STM32_SRAM1_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/libraries/templates/stm32l5xx/board/board.h b/bsp/stm32/libraries/templates/stm32l5xx/board/board.h index 049dfd05fb..479a4262fb 100644 --- a/bsp/stm32/libraries/templates/stm32l5xx/board/board.h +++ b/bsp/stm32/libraries/templates/stm32l5xx/board/board.h @@ -29,7 +29,7 @@ extern "C" { #define STM32_SRAM1_START (0x20000000) #define STM32_SRAM1_END (STM32_SRAM1_START + STM32_SRAM1_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/libraries/templates/stm32mp1xx/board/board.h b/bsp/stm32/libraries/templates/stm32mp1xx/board/board.h index b23b83ee30..ecf4c1a88f 100644 --- a/bsp/stm32/libraries/templates/stm32mp1xx/board/board.h +++ b/bsp/stm32/libraries/templates/stm32mp1xx/board/board.h @@ -29,7 +29,7 @@ extern "C" { #define STM32_SRAM_SIZE (128) #define STM32_SRAM_END ((uint32_t)0x10040000 + (STM32_SRAM_SIZE * 1024)) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/libraries/templates/stm32wbxx/board/board.h b/bsp/stm32/libraries/templates/stm32wbxx/board/board.h index d77bf172ba..6585a352c7 100644 --- a/bsp/stm32/libraries/templates/stm32wbxx/board/board.h +++ b/bsp/stm32/libraries/templates/stm32wbxx/board/board.h @@ -29,7 +29,7 @@ extern "C" { #define STM32_SRAM1_START (0x20000000) #define STM32_SRAM1_END (STM32_SRAM1_START + STM32_SRAM1_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f072-st-nucleo/board/board.h b/bsp/stm32/stm32f072-st-nucleo/board/board.h index 51a9f80edd..4dc58c3c92 100644 --- a/bsp/stm32/stm32f072-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f072-st-nucleo/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 16 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f091-st-nucleo/board/board.h b/bsp/stm32/stm32f091-st-nucleo/board/board.h index a9ba91377d..efd152dc0d 100644 --- a/bsp/stm32/stm32f091-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f091-st-nucleo/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 32 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f103-atk-nano/board/board.h b/bsp/stm32/stm32f103-atk-nano/board/board.h index 498459073e..05d7bdaf2d 100644 --- a/bsp/stm32/stm32f103-atk-nano/board/board.h +++ b/bsp/stm32/stm32f103-atk-nano/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE 20 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f103-atk-warshipv3/board/board.h b/bsp/stm32/stm32f103-atk-warshipv3/board/board.h index 80c80984bf..023339a177 100644 --- a/bsp/stm32/stm32f103-atk-warshipv3/board/board.h +++ b/bsp/stm32/stm32f103-atk-warshipv3/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 64 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f103-blue-pill/board/board.h b/bsp/stm32/stm32f103-blue-pill/board/board.h index 1be364929a..aaa6eeafc0 100644 --- a/bsp/stm32/stm32f103-blue-pill/board/board.h +++ b/bsp/stm32/stm32f103-blue-pill/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 20 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f103-dofly-M3S/board/board.h b/bsp/stm32/stm32f103-dofly-M3S/board/board.h index 8662bff0f5..8403f451d4 100644 --- a/bsp/stm32/stm32f103-dofly-M3S/board/board.h +++ b/bsp/stm32/stm32f103-dofly-M3S/board/board.h @@ -29,7 +29,7 @@ extern "C" { #define STM32_SRAM_SIZE 64 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f103-dofly-lyc8/board/board.h b/bsp/stm32/stm32f103-dofly-lyc8/board/board.h index 8d8cc4643a..3d813a0af0 100644 --- a/bsp/stm32/stm32f103-dofly-lyc8/board/board.h +++ b/bsp/stm32/stm32f103-dofly-lyc8/board/board.h @@ -23,7 +23,7 @@ #define STM32_SRAM_SIZE 20 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f103-fire-arbitrary/board/board.h b/bsp/stm32/stm32f103-fire-arbitrary/board/board.h index 7aa3c0f703..3cc20b82e4 100644 --- a/bsp/stm32/stm32f103-fire-arbitrary/board/board.h +++ b/bsp/stm32/stm32f103-fire-arbitrary/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_FLASH_SIZE (512 * 1024) #define STM32_FLASH_END_ADDRESS ((uint32_t)(STM32_FLASH_START_ADRESS + STM32_FLASH_SIZE)) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f103-gizwits-gokitv21/board/board.h b/bsp/stm32/stm32f103-gizwits-gokitv21/board/board.h index cdb13091cd..6c852d9609 100644 --- a/bsp/stm32/stm32f103-gizwits-gokitv21/board/board.h +++ b/bsp/stm32/stm32f103-gizwits-gokitv21/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 20 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f103-hw100k-ibox/board/board.h b/bsp/stm32/stm32f103-hw100k-ibox/board/board.h index 239f0afdd6..3dfff3bdb0 100644 --- a/bsp/stm32/stm32f103-hw100k-ibox/board/board.h +++ b/bsp/stm32/stm32f103-hw100k-ibox/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 64 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f103-onenet-nbiot/board/board.h b/bsp/stm32/stm32f103-onenet-nbiot/board/board.h index 162925a4f3..2e5f93a0bb 100644 --- a/bsp/stm32/stm32f103-onenet-nbiot/board/board.h +++ b/bsp/stm32/stm32f103-onenet-nbiot/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE 64 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f103-yf-ufun/board/board.h b/bsp/stm32/stm32f103-yf-ufun/board/board.h index 738f37080a..fa0ff3fed2 100644 --- a/bsp/stm32/stm32f103-yf-ufun/board/board.h +++ b/bsp/stm32/stm32f103-yf-ufun/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 48 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f107-uc-eval/board/board.h b/bsp/stm32/stm32f107-uc-eval/board/board.h index 44a96208c6..ce1681ba28 100644 --- a/bsp/stm32/stm32f107-uc-eval/board/board.h +++ b/bsp/stm32/stm32f107-uc-eval/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 64 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f207-st-nucleo/board/board.h b/bsp/stm32/stm32f207-st-nucleo/board/board.h index 77143ecb0e..b7b40bb799 100644 --- a/bsp/stm32/stm32f207-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f207-st-nucleo/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 128 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f302-st-nucleo/board/board.h b/bsp/stm32/stm32f302-st-nucleo/board/board.h index 1de41e4a63..de61eb7514 100644 --- a/bsp/stm32/stm32f302-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f302-st-nucleo/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE 16 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f401-st-nucleo/board/board.h b/bsp/stm32/stm32f401-st-nucleo/board/board.h index 82647a83a4..93a2407c87 100644 --- a/bsp/stm32/stm32f401-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f401-st-nucleo/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE 96 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f405-smdz-breadfruit/board/board.h b/bsp/stm32/stm32f405-smdz-breadfruit/board/board.h index 844f5e35e6..64d30cc5b7 100644 --- a/bsp/stm32/stm32f405-smdz-breadfruit/board/board.h +++ b/bsp/stm32/stm32f405-smdz-breadfruit/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE (128) #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f407-armfly-v5/board/board.h b/bsp/stm32/stm32f407-armfly-v5/board/board.h index 68016d18bd..00108ee123 100644 --- a/bsp/stm32/stm32f407-armfly-v5/board/board.h +++ b/bsp/stm32/stm32f407-armfly-v5/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE 128 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f407-atk-explorer/applications/lvgl/lv_port_disp.c b/bsp/stm32/stm32f407-atk-explorer/applications/lvgl/lv_port_disp.c index fb38b870ec..30da608bdc 100644 --- a/bsp/stm32/stm32f407-atk-explorer/applications/lvgl/lv_port_disp.c +++ b/bsp/stm32/stm32f407-atk-explorer/applications/lvgl/lv_port_disp.c @@ -26,7 +26,7 @@ static lv_disp_drv_t disp_drv; lv_color_t buf_1[LCD_H * LCD_W]; #elif defined ( __CC_ARM ) /* MDK ARM Compiler */ __attribute__((at(0x68000000))) lv_color_t buf_1[LCD_H * LCD_W]; -#elif defined ( __CLANG_ARM ) /* MDK ARM Compiler v6 */ +#elif defined ( __clang__ ) /* MDK ARM Compiler v6 */ __attribute__((section(".ARM.__at_0x68000000"))) lv_color_t buf_1[LCD_H * LCD_W]; #elif defined ( __GNUC__ ) /* GNU Compiler */ lv_color_t buf_1[LCD_H * LCD_W] __attribute__((section(".MCUlcdgrambysram"))); diff --git a/bsp/stm32/stm32f407-atk-explorer/board/board.h b/bsp/stm32/stm32f407-atk-explorer/board/board.h index 6d80e38f78..b88f85a064 100644 --- a/bsp/stm32/stm32f407-atk-explorer/board/board.h +++ b/bsp/stm32/stm32f407-atk-explorer/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_FLASH_SIZE (1024 * 1024) #define STM32_FLASH_END_ADDRESS ((uint32_t)(STM32_FLASH_START_ADRESS + STM32_FLASH_SIZE)) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f407-robomaster-c/board/board.h b/bsp/stm32/stm32f407-robomaster-c/board/board.h index 25e4852c4c..92b9520169 100644 --- a/bsp/stm32/stm32f407-robomaster-c/board/board.h +++ b/bsp/stm32/stm32f407-robomaster-c/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 128 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f407-st-discovery/board/board.h b/bsp/stm32/stm32f407-st-discovery/board/board.h index 539e3abf45..ca3b4f8b24 100644 --- a/bsp/stm32/stm32f407-st-discovery/board/board.h +++ b/bsp/stm32/stm32f407-st-discovery/board/board.h @@ -23,7 +23,7 @@ extern "C" { #define STM32_SRAM_SIZE (128) #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f410-st-nucleo/board/board.h b/bsp/stm32/stm32f410-st-nucleo/board/board.h index 72bd8a017c..122ee1b524 100644 --- a/bsp/stm32/stm32f410-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f410-st-nucleo/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE 32 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f411-atk-nano/board/board.h b/bsp/stm32/stm32f411-atk-nano/board/board.h index 2cbe75f5d9..f301f3f527 100644 --- a/bsp/stm32/stm32f411-atk-nano/board/board.h +++ b/bsp/stm32/stm32f411-atk-nano/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE 128 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f411-st-nucleo/board/board.h b/bsp/stm32/stm32f411-st-nucleo/board/board.h index 062038ffdb..25b839b380 100644 --- a/bsp/stm32/stm32f411-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f411-st-nucleo/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE 128 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f411-weact-MiniF4/board/board.h b/bsp/stm32/stm32f411-weact-MiniF4/board/board.h index 062038ffdb..25b839b380 100644 --- a/bsp/stm32/stm32f411-weact-MiniF4/board/board.h +++ b/bsp/stm32/stm32f411-weact-MiniF4/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE 128 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f412-st-nucleo/board/board.h b/bsp/stm32/stm32f412-st-nucleo/board/board.h index 5c463d04e8..8d1465a1c9 100644 --- a/bsp/stm32/stm32f412-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f412-st-nucleo/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE 256 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f413-st-nucleo/board/board.h b/bsp/stm32/stm32f413-st-nucleo/board/board.h index 634003f596..e98990ce75 100644 --- a/bsp/stm32/stm32f413-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f413-st-nucleo/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE 320 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f427-robomaster-a/board/board.h b/bsp/stm32/stm32f427-robomaster-a/board/board.h index a0ea5ca4bd..0e3a162bae 100644 --- a/bsp/stm32/stm32f427-robomaster-a/board/board.h +++ b/bsp/stm32/stm32f427-robomaster-a/board/board.h @@ -29,7 +29,7 @@ extern "C" { #define STM32_SRAM1_START (0x20000000) #define STM32_SRAM1_END (STM32_SRAM1_START + STM32_SRAM1_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f429-armfly-v6/board/board.h b/bsp/stm32/stm32f429-armfly-v6/board/board.h index c0d30df246..102b68f765 100644 --- a/bsp/stm32/stm32f429-armfly-v6/board/board.h +++ b/bsp/stm32/stm32f429-armfly-v6/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_FLASH_SIZE (2 * 1024 * 1024) #define STM32_FLASH_END_ADDRESS ((uint32_t)(STM32_FLASH_START_ADRESS + STM32_FLASH_SIZE)) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f429-atk-apollo/board/board.h b/bsp/stm32/stm32f429-atk-apollo/board/board.h index 077b0af713..e07f601b84 100644 --- a/bsp/stm32/stm32f429-atk-apollo/board/board.h +++ b/bsp/stm32/stm32f429-atk-apollo/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE (192) #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f429-fire-challenger/board/board.h b/bsp/stm32/stm32f429-fire-challenger/board/board.h index c51f6a93cc..6a205b9393 100644 --- a/bsp/stm32/stm32f429-fire-challenger/board/board.h +++ b/bsp/stm32/stm32f429-fire-challenger/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_FLASH_SIZE (1024 * 1024) #define STM32_FLASH_END_ADDRESS ((uint32_t)(STM32_FLASH_START_ADRESS + STM32_FLASH_SIZE)) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f429-st-disco/board/board.h b/bsp/stm32/stm32f429-st-disco/board/board.h index ce8f2cc591..650b64a256 100644 --- a/bsp/stm32/stm32f429-st-disco/board/board.h +++ b/bsp/stm32/stm32f429-st-disco/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE (256 - 64) #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f446-st-nucleo/board/board.h b/bsp/stm32/stm32f446-st-nucleo/board/board.h index 8cb4438f8b..3da6cda6d2 100644 --- a/bsp/stm32/stm32f446-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f446-st-nucleo/board/board.h @@ -24,7 +24,7 @@ #define STM32_SRAM_SIZE 128 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f469-st-disco/board/board.h b/bsp/stm32/stm32f469-st-disco/board/board.h index 607aa3877d..14f3a6f037 100644 --- a/bsp/stm32/stm32f469-st-disco/board/board.h +++ b/bsp/stm32/stm32f469-st-disco/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE (384 - 64) #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f746-st-disco/board/board.h b/bsp/stm32/stm32f746-st-disco/board/board.h index b0c120fb41..877bb022cf 100644 --- a/bsp/stm32/stm32f746-st-disco/board/board.h +++ b/bsp/stm32/stm32f746-st-disco/board/board.h @@ -23,7 +23,7 @@ #define STM32_SRAM_SIZE (320) #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f746-st-nucleo/board/board.h b/bsp/stm32/stm32f746-st-nucleo/board/board.h index 3b37641ec9..0abf5077eb 100644 --- a/bsp/stm32/stm32f746-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f746-st-nucleo/board/board.h @@ -23,7 +23,7 @@ #define STM32_SRAM_SIZE (256) #define STM32_SRAM_END (0x20010000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f767-atk-apollo/board/board.h b/bsp/stm32/stm32f767-atk-apollo/board/board.h index e91271055e..807daaa757 100644 --- a/bsp/stm32/stm32f767-atk-apollo/board/board.h +++ b/bsp/stm32/stm32f767-atk-apollo/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE (512) #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f767-fire-challenger-v1/board/board.h b/bsp/stm32/stm32f767-fire-challenger-v1/board/board.h index e9a1277849..cb7fa73806 100644 --- a/bsp/stm32/stm32f767-fire-challenger-v1/board/board.h +++ b/bsp/stm32/stm32f767-fire-challenger-v1/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_FLASH_SIZE (1024 * 1024) #define STM32_FLASH_END_ADDRESS ((uint32_t)(STM32_FLASH_START_ADRESS + STM32_FLASH_SIZE)) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f767-st-nucleo/board/board.h b/bsp/stm32/stm32f767-st-nucleo/board/board.h index 1d82defe0d..a721a56fc4 100644 --- a/bsp/stm32/stm32f767-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f767-st-nucleo/board/board.h @@ -24,7 +24,7 @@ #define STM32_SRAM_SIZE (512) #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32f769-st-disco/board/board.h b/bsp/stm32/stm32f769-st-disco/board/board.h index 813dd5b27e..5694d51bd4 100644 --- a/bsp/stm32/stm32f769-st-disco/board/board.h +++ b/bsp/stm32/stm32f769-st-disco/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE (512) #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32g070-st-nucleo/board/board.h b/bsp/stm32/stm32g070-st-nucleo/board/board.h index d36387892b..d492da1eb9 100644 --- a/bsp/stm32/stm32g070-st-nucleo/board/board.h +++ b/bsp/stm32/stm32g070-st-nucleo/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 36 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32g071-st-nucleo/board/board.h b/bsp/stm32/stm32g071-st-nucleo/board/board.h index d36387892b..d492da1eb9 100644 --- a/bsp/stm32/stm32g071-st-nucleo/board/board.h +++ b/bsp/stm32/stm32g071-st-nucleo/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 36 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32g431-st-nucleo/board/board.h b/bsp/stm32/stm32g431-st-nucleo/board/board.h index 6fd0c97890..d7d48a2db7 100644 --- a/bsp/stm32/stm32g431-st-nucleo/board/board.h +++ b/bsp/stm32/stm32g431-st-nucleo/board/board.h @@ -24,7 +24,7 @@ #define STM32_SRAM_SIZE 32 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32g474-st-nucleo/board/board.h b/bsp/stm32/stm32g474-st-nucleo/board/board.h index 6fd0c97890..d7d48a2db7 100644 --- a/bsp/stm32/stm32g474-st-nucleo/board/board.h +++ b/bsp/stm32/stm32g474-st-nucleo/board/board.h @@ -24,7 +24,7 @@ #define STM32_SRAM_SIZE 32 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32h743-armfly-V7/board/board.h b/bsp/stm32/stm32h743-armfly-V7/board/board.h index 32eb25f147..d511a1f847 100644 --- a/bsp/stm32/stm32h743-armfly-V7/board/board.h +++ b/bsp/stm32/stm32h743-armfly-V7/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE (512) #define STM32_SRAM_END (0x24000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32h743-atk-apollo/board/board.h b/bsp/stm32/stm32h743-atk-apollo/board/board.h index c9ec7a30d9..10fe8dae36 100644 --- a/bsp/stm32/stm32h743-atk-apollo/board/board.h +++ b/bsp/stm32/stm32h743-atk-apollo/board/board.h @@ -31,7 +31,7 @@ extern "C" { #define STM32_SRAM_SIZE (512) #define STM32_SRAM_END (0x24000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32h743-openmv-h7plus/board/board.h b/bsp/stm32/stm32h743-openmv-h7plus/board/board.h index c2bf0c0323..b1e723057d 100644 --- a/bsp/stm32/stm32h743-openmv-h7plus/board/board.h +++ b/bsp/stm32/stm32h743-openmv-h7plus/board/board.h @@ -29,7 +29,7 @@ extern "C" { #define STM32_SRAM1_START (0x20000000) #define STM32_SRAM1_END (STM32_SRAM1_START + STM32_SRAM1_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32h743-st-nucleo/board/board.h b/bsp/stm32/stm32h743-st-nucleo/board/board.h index 32eb25f147..d511a1f847 100644 --- a/bsp/stm32/stm32h743-st-nucleo/board/board.h +++ b/bsp/stm32/stm32h743-st-nucleo/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE (512) #define STM32_SRAM_END (0x24000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32h747-st-discovery/board/board.h b/bsp/stm32/stm32h747-st-discovery/board/board.h index 85196a7664..f13926d8a7 100644 --- a/bsp/stm32/stm32h747-st-discovery/board/board.h +++ b/bsp/stm32/stm32h747-st-discovery/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE (128) #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32h750-armfly-h7-tool/board/board.h b/bsp/stm32/stm32h750-armfly-h7-tool/board/board.h index b41ed17e43..657a668b64 100644 --- a/bsp/stm32/stm32h750-armfly-h7-tool/board/board.h +++ b/bsp/stm32/stm32h750-armfly-h7-tool/board/board.h @@ -27,7 +27,7 @@ extern "C" { #define STM32_SRAM_SIZE (128) #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32h750-artpi-h750/board/board.h b/bsp/stm32/stm32h750-artpi-h750/board/board.h index ac48db06bf..61b43c8c23 100644 --- a/bsp/stm32/stm32h750-artpi-h750/board/board.h +++ b/bsp/stm32/stm32h750-artpi-h750/board/board.h @@ -77,7 +77,7 @@ extern "C" { #define STM32_SRAM1_START RAM_START #define STM32_SRAM1_END RAM_END -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32l010-st-nucleo/board/board.h b/bsp/stm32/stm32l010-st-nucleo/board/board.h index 67e4ad5ec0..3e6096d63d 100644 --- a/bsp/stm32/stm32l010-st-nucleo/board/board.h +++ b/bsp/stm32/stm32l010-st-nucleo/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 20 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32l053-st-nucleo/board/board.h b/bsp/stm32/stm32l053-st-nucleo/board/board.h index f88ee51946..91745ef064 100644 --- a/bsp/stm32/stm32l053-st-nucleo/board/board.h +++ b/bsp/stm32/stm32l053-st-nucleo/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM_SIZE 8 #define STM32_SRAM_END (0x20000000 + STM32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32l433-ali-startkit/board/board.h b/bsp/stm32/stm32l433-ali-startkit/board/board.h index 5046836891..59c7733604 100644 --- a/bsp/stm32/stm32l433-ali-startkit/board/board.h +++ b/bsp/stm32/stm32l433-ali-startkit/board/board.h @@ -34,7 +34,7 @@ extern "C" { #define STM32_FLASH_SIZE (256 * 1024) #define STM32_FLASH_END_ADDRESS ((uint32_t)(STM32_FLASH_START_ADRESS + STM32_FLASH_SIZE)) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32l452-st-nucleo/board/board.h b/bsp/stm32/stm32l452-st-nucleo/board/board.h index 0c9006dc40..9c481c4983 100644 --- a/bsp/stm32/stm32l452-st-nucleo/board/board.h +++ b/bsp/stm32/stm32l452-st-nucleo/board/board.h @@ -29,7 +29,7 @@ extern "C" { #define STM32_SRAM1_START (0x20000000) #define STM32_SRAM1_END (STM32_SRAM1_START + STM32_SRAM1_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32l475-atk-pandora/board/board.h b/bsp/stm32/stm32l475-atk-pandora/board/board.h index a1029a3e99..c91fb31d23 100644 --- a/bsp/stm32/stm32l475-atk-pandora/board/board.h +++ b/bsp/stm32/stm32l475-atk-pandora/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM1_START (0x20000000) #define STM32_SRAM1_END (STM32_SRAM1_START + STM32_SRAM1_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32l496-ali-developer/board/board.h b/bsp/stm32/stm32l496-ali-developer/board/board.h index 8c0daff8b5..dc2db87b70 100644 --- a/bsp/stm32/stm32l496-ali-developer/board/board.h +++ b/bsp/stm32/stm32l496-ali-developer/board/board.h @@ -39,7 +39,7 @@ extern "C" { #define STM32_FLASH_SIZE (1024 * 1024) #define STM32_FLASH_END_ADDRESS ((uint32_t)(STM32_FLASH_START_ADRESS + STM32_FLASH_SIZE)) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32l496-st-nucleo/board/board.h b/bsp/stm32/stm32l496-st-nucleo/board/board.h index f9edac21da..63f09134c0 100644 --- a/bsp/stm32/stm32l496-st-nucleo/board/board.h +++ b/bsp/stm32/stm32l496-st-nucleo/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM1_START (0x20000000) #define STM32_SRAM1_END (STM32_SRAM1_START + STM32_SRAM1_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32l4r9-st-sensortile-box/board/board.h b/bsp/stm32/stm32l4r9-st-sensortile-box/board/board.h index 049be64f38..9a9df06b23 100644 --- a/bsp/stm32/stm32l4r9-st-sensortile-box/board/board.h +++ b/bsp/stm32/stm32l4r9-st-sensortile-box/board/board.h @@ -28,7 +28,7 @@ extern "C" { #define STM32_SRAM1_START (0x20000000) #define STM32_SRAM1_END (STM32_SRAM1_START + STM32_SRAM1_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32l552-st-nucleo/board/board.h b/bsp/stm32/stm32l552-st-nucleo/board/board.h index 049dfd05fb..479a4262fb 100644 --- a/bsp/stm32/stm32l552-st-nucleo/board/board.h +++ b/bsp/stm32/stm32l552-st-nucleo/board/board.h @@ -29,7 +29,7 @@ extern "C" { #define STM32_SRAM1_START (0x20000000) #define STM32_SRAM1_END (STM32_SRAM1_START + STM32_SRAM1_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32mp157a-st-discovery/board/board.h b/bsp/stm32/stm32mp157a-st-discovery/board/board.h index 0b60c68af4..332f4ad308 100644 --- a/bsp/stm32/stm32mp157a-st-discovery/board/board.h +++ b/bsp/stm32/stm32mp157a-st-discovery/board/board.h @@ -29,7 +29,7 @@ extern "C" { #define STM32_SRAM_SIZE (64) #define STM32_SRAM_END (0x10030000 + 64 * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32mp157a-st-discovery/board/ports/audio/drv_mic.c b/bsp/stm32/stm32mp157a-st-discovery/board/ports/audio/drv_mic.c index 45b0afe762..35c4d0a342 100644 --- a/bsp/stm32/stm32mp157a-st-discovery/board/ports/audio/drv_mic.c +++ b/bsp/stm32/stm32mp157a-st-discovery/board/ports/audio/drv_mic.c @@ -24,7 +24,7 @@ /* SYSRAM */ #define RX_FIFO_SIZE (4096) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) rt_uint8_t MIC_RX_FIFO[RX_FIFO_SIZE] __attribute__((at(0x2FFC2000))); #elif defined(__ICCARM__) #pragma location = 0x2FFC2000 diff --git a/bsp/stm32/stm32mp157a-st-discovery/board/ports/audio/drv_sound.c b/bsp/stm32/stm32mp157a-st-discovery/board/ports/audio/drv_sound.c index 6a057fa72f..89f7704145 100644 --- a/bsp/stm32/stm32mp157a-st-discovery/board/ports/audio/drv_sound.c +++ b/bsp/stm32/stm32mp157a-st-discovery/board/ports/audio/drv_sound.c @@ -22,7 +22,7 @@ /* SYSRAM */ #define TX_FIFO_SIZE (4096) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) rt_uint8_t AUDIO_TX_FIFO[TX_FIFO_SIZE] __attribute__((at(0x2FFC3000))); #elif defined(__ICCARM__) #pragma location = 0x2FFC3000 diff --git a/bsp/stm32/stm32mp157a-st-discovery/board/ports/drv_eth.c b/bsp/stm32/stm32mp157a-st-discovery/board/ports/drv_eth.c index 229c3e585e..8de506591a 100644 --- a/bsp/stm32/stm32mp157a-st-discovery/board/ports/drv_eth.c +++ b/bsp/stm32/stm32mp157a-st-discovery/board/ports/drv_eth.c @@ -44,7 +44,7 @@ static TxDmaDesc txDmaDesc[ETH_TXBUFNB]; #pragma location = RX_DMA_ADD_BASE static RxDmaDesc rxDmaDesc[ETH_RXBUFNB]; -#elif defined(__CC_ARM) || defined(__CLANG_ARM) +#elif defined(__ARMCC_VERSION) /* transmit buffer */ static rt_uint8_t txBuffer[ETH_TXBUFNB][ETH_TX_BUF_SIZE] __attribute__((at(TX_ADD_BASE))); /* Receive buffer */ diff --git a/bsp/stm32/stm32mp157a-st-discovery/board/ports/drv_sdio.c b/bsp/stm32/stm32mp157a-st-discovery/board/ports/drv_sdio.c index 9d128a2892..21d207c24c 100644 --- a/bsp/stm32/stm32mp157a-st-discovery/board/ports/drv_sdio.c +++ b/bsp/stm32/stm32mp157a-st-discovery/board/ports/drv_sdio.c @@ -55,7 +55,7 @@ struct rthw_sdio /* SYSRAM SDMMC1/2 accesses */ #define SDCARD_ADDR 0x2FFFF000 -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) __attribute__((at(SDCARD_ADDR))) static rt_uint8_t cache_buf[SDIO_BUFF_SIZE]; #elif defined ( __GNUC__ ) static rt_uint8_t cache_buf[SDIO_BUFF_SIZE] __attribute__((section(".SdCardSection"))); diff --git a/bsp/stm32/stm32mp157a-st-ev1/board/board.h b/bsp/stm32/stm32mp157a-st-ev1/board/board.h index 0406e49952..5775caf20b 100644 --- a/bsp/stm32/stm32mp157a-st-ev1/board/board.h +++ b/bsp/stm32/stm32mp157a-st-ev1/board/board.h @@ -30,7 +30,7 @@ extern "C" { #define STM32_SRAM_SIZE (64) #define STM32_SRAM_END (0x10030000 + 64 * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_dfsdm.c b/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_dfsdm.c index 61600fbd00..990537241e 100644 --- a/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_dfsdm.c +++ b/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_dfsdm.c @@ -19,7 +19,7 @@ #include #define FILTER_FIFO_SIZE (1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) __attribute__((at(0x2FFC8000))) static rt_int32_t FILTER0_FIFO[FILTER_FIFO_SIZE]; #elif defined ( __GNUC__ ) static rt_int32_t FILTER0_FIFO[FILTER_FIFO_SIZE] __attribute__((section(".Filter0Section"))); @@ -28,7 +28,7 @@ static rt_int32_t FILTER0_FIFO[FILTER_FIFO_SIZE] __attribute__((section(".Filter __no_init static rt_int32_t FILTER0_FIFO[FILTER_FIFO_SIZE]; #endif -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) __attribute__((at(0x2FFC9000))) static rt_int32_t FILTER0_FIFO[FILTER_FIFO_SIZE]; #elif defined ( __GNUC__ ) static rt_int32_t FILTER0_FIFO[FILTER_FIFO_SIZE] __attribute__((section(".Filter1Section"))); @@ -38,7 +38,7 @@ __no_init static rt_int32_t FILTER1_FIFO[FILTER_FIFO_SIZE]; #endif #define PALY_SIZE 2048 -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) __attribute__((at(0x2FFCA000))) static rt_int16_t PLAY_BUF[PALY_SIZE]; #elif defined ( __GNUC__ ) __attribute__((at(0x2FFCA000))) __attribute__((section(".DfsdmSection"))); diff --git a/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_emmc.c b/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_emmc.c index 2da6ddc485..b935c40df2 100644 --- a/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_emmc.c +++ b/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_emmc.c @@ -50,7 +50,7 @@ struct rthw_sdio #define EMMC_BUFF_SIZE 4096 #define EMMC_BUFF_ADDR 0x2FFCB000 -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) __attribute__((at(EMMC_BUFF_ADDR))) static rt_uint8_t cache_buf[EMMC_BUFF_SIZE]; #elif defined ( __GNUC__ ) static rt_uint8_t cache_buf[EMMC_BUFF_SIZE] __attribute__((section(".eMMCSection"))); diff --git a/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_ov5640.c b/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_ov5640.c index da4d602a67..69af85e27b 100644 --- a/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_ov5640.c +++ b/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_ov5640.c @@ -27,7 +27,7 @@ #define JPEG_BUF_SIZE 8 * 1024 #define JPEG_LINE_SIZE 1 * 1024 -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) __attribute__((at(0x2FFCC000))) static rt_int32_t JPEG_DATA_BUF[JPEG_BUF_SIZE]; #elif defined(__GNUC__) static rt_int32_t JPEG_DATA_BUF[JPEG_BUF_SIZE] __attribute__((section(".Dcmi0Section"))); @@ -36,7 +36,7 @@ static rt_int32_t JPEG_DATA_BUF[JPEG_BUF_SIZE] __attribute__((section(".Dcmi0Sec __no_init static rt_int32_t JPEG_DATA_BUF[JPEG_BUF_SIZE]; #endif -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) __attribute__((at(0x2FFDC000))) static rt_int32_t JPEG_LINE_BUF[2][JPEG_LINE_SIZE]; #elif defined(__GNUC__) static rt_int32_t JPEG_LINE_BUF[2][JPEG_LINE_SIZE] __attribute__((section(".Dcmi1Section"))); diff --git a/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_sdcard.c b/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_sdcard.c index bb6e92584f..b8f524e59a 100644 --- a/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_sdcard.c +++ b/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_sdcard.c @@ -42,7 +42,7 @@ struct rt_completion rx_comp; /* SYSRAM SDMMC1/2 accesses */ #define SDIO_BUFF_SIZE 512 #define SDCARD_ADDR 0x2FFC0000 -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) __attribute__((at(SDCARD_ADDR))) static rt_uint32_t cache_buf[SDIO_BUFF_SIZE]; #elif defined ( __GNUC__ ) static rt_uint32_t cache_buf[SDIO_BUFF_SIZE] __attribute__((section(".SdCardSection"))); diff --git a/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_sound.c b/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_sound.c index 4aee045825..b9e76a0703 100644 --- a/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_sound.c +++ b/bsp/stm32/stm32mp157a-st-ev1/board/ports/drv_sound.c @@ -22,7 +22,7 @@ #define SOUND_BUS_NAME "i2c2" #define TX_FIFO_SIZE (4096) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) __attribute__((at(0x2FFC2000))) static rt_uint8_t AUDIO_TX_FIFO[TX_FIFO_SIZE]; #elif defined ( __GNUC__ ) static rt_uint8_t AUDIO_TX_FIFO[TX_FIFO_SIZE] __attribute__((section(".AudioSection"))); diff --git a/bsp/stm32/stm32mp157a-st-ev1/board/ports/eth/drv_eth.c b/bsp/stm32/stm32mp157a-st-ev1/board/ports/eth/drv_eth.c index 670a00e35e..4f7bea280d 100644 --- a/bsp/stm32/stm32mp157a-st-ev1/board/ports/eth/drv_eth.c +++ b/bsp/stm32/stm32mp157a-st-ev1/board/ports/eth/drv_eth.c @@ -44,7 +44,7 @@ __no_init static TxDmaDesc txDmaDesc[ETH_TXBUFNB]; #pragma location = RX_DMA_ADD_BASE __no_init static RxDmaDesc rxDmaDesc[ETH_RXBUFNB]; -#elif defined(__CC_ARM) || defined(__CLANG_ARM) +#elif defined(__ARMCC_VERSION) /* transmit buffer */ static rt_uint8_t txBuffer[ETH_TXBUFNB][ETH_TX_BUF_SIZE] __attribute__((at(TX_ADD_BASE))); /* Receive buffer */ diff --git a/bsp/stm32/stm32u575-st-nucleo/board/board.h b/bsp/stm32/stm32u575-st-nucleo/board/board.h index 8a5abd8190..21566e54c8 100644 --- a/bsp/stm32/stm32u575-st-nucleo/board/board.h +++ b/bsp/stm32/stm32u575-st-nucleo/board/board.h @@ -29,7 +29,7 @@ extern "C" { #define STM32_SRAM1_START (0x20000000) #define STM32_SRAM1_END (STM32_SRAM1_START + STM32_SRAM1_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/stm32/stm32wb55-st-nucleo/board/board.h b/bsp/stm32/stm32wb55-st-nucleo/board/board.h index 366ef99b50..869826a3c2 100644 --- a/bsp/stm32/stm32wb55-st-nucleo/board/board.h +++ b/bsp/stm32/stm32wb55-st-nucleo/board/board.h @@ -29,7 +29,7 @@ extern "C" { #define STM32_SRAM1_START (0x20000000) #define STM32_SRAM1_END (STM32_SRAM1_START + STM32_SRAM1_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/swm320-lq100/drivers/board.h b/bsp/swm320-lq100/drivers/board.h index 223018920f..c139890e57 100644 --- a/bsp/swm320-lq100/drivers/board.h +++ b/bsp/swm320-lq100/drivers/board.h @@ -34,7 +34,7 @@ extern "C" #define EXT_SRAM_END (EXT_SRAM_BASE + EXT_SRAM_SIZE) #endif -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/swm320/drivers/board.h b/bsp/swm320/drivers/board.h index 223018920f..c139890e57 100644 --- a/bsp/swm320/drivers/board.h +++ b/bsp/swm320/drivers/board.h @@ -34,7 +34,7 @@ extern "C" #define EXT_SRAM_END (EXT_SRAM_BASE + EXT_SRAM_SIZE) #endif -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/tm4c123bsp/board/board.h b/bsp/tm4c123bsp/board/board.h index f12ba9c5b5..0f8c5aff40 100644 --- a/bsp/tm4c123bsp/board/board.h +++ b/bsp/tm4c123bsp/board/board.h @@ -18,7 +18,7 @@ #define TM4C123_SRAM1_START (0x20000000) #define TM4C123_SRAM1_END (TM4C123_SRAM1_START + 32 * 1024) // end address = 0x20000000(base adddress) + 32K(RAM size) - #if defined(__CC_ARM) || defined(__CLANG_ARM) + #if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM$$ZI$$Limit; // RW_IRAM #define HEAP_BEGIN ((void *)&Image$$RW_IRAM$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/wch/arm/ch32f103c8-core/board/board.h b/bsp/wch/arm/ch32f103c8-core/board/board.h index a606f4dc03..f4073203a7 100644 --- a/bsp/wch/arm/ch32f103c8-core/board/board.h +++ b/bsp/wch/arm/ch32f103c8-core/board/board.h @@ -26,7 +26,7 @@ extern "C" { #define CH32_SRAM_SIZE 20 #define CH32_SRAM_END (0x20000000 + CH32_SRAM_SIZE * 1024) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/bsp/yichip/yc3121-pos/drivers/board.h b/bsp/yichip/yc3121-pos/drivers/board.h index 573c6454a9..59b21029e8 100644 --- a/bsp/yichip/yc3121-pos/drivers/board.h +++ b/bsp/yichip/yc3121-pos/drivers/board.h @@ -28,7 +28,7 @@ #endif #define SRAM_END (SRAM_BASE + SRAM_SIZE) -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int Image$$RW_IRAM1$$ZI$$Limit; #define HEAP_BEGIN ((void *)&Image$$RW_IRAM1$$ZI$$Limit) #elif __ICCARM__ diff --git a/components/cplusplus/cxx_crt_init.c b/components/cplusplus/cxx_crt_init.c index 977dee6ee9..46946089ff 100644 --- a/components/cplusplus/cxx_crt_init.c +++ b/components/cplusplus/cxx_crt_init.c @@ -13,7 +13,7 @@ #include -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern void $Super$$__cpp_initialize__aeabi_(void); /* we need to change the cpp_initialize order */ RT_WEAK void $Sub$$__cpp_initialize__aeabi_(void) @@ -36,7 +36,7 @@ RT_WEAK void *__dso_handle = 0; RT_WEAK int cplusplus_system_init(void) { -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) /* If there is no SHT$$INIT_ARRAY, calling * $Super$$__cpp_initialize__aeabi_() will cause fault. At least until Keil5.12 * the problem still exists. So we have to initialize the C++ runtime by ourself. diff --git a/components/libc/compilers/armlibc/syscalls.c b/components/libc/compilers/armlibc/syscalls.c index 54d8b40bf6..14b47d3627 100644 --- a/components/libc/compilers/armlibc/syscalls.c +++ b/components/libc/compilers/armlibc/syscalls.c @@ -30,11 +30,11 @@ #define DBG_LVL DBG_INFO #include -#ifdef __CLANG_ARM +#ifdef __clang__ __asm(".global __use_no_semihosting\n\t"); #else #pragma import(__use_no_semihosting_swi) -#endif /* __CLANG_ARM */ +#endif /* Standard IO device handles. */ #define STDIN 0 diff --git a/components/utilities/utest/utest.c b/components/utilities/utest/utest.c index 7103efb89c..8c8ffd674a 100644 --- a/components/utilities/utest/utest.c +++ b/components/utilities/utest/utest.c @@ -68,7 +68,7 @@ void utest_log_lv_set(rt_uint8_t lv) int utest_init(void) { /* initialize the utest commands table.*/ -#if defined(__CC_ARM) || defined(__CLANG_ARM) /* ARM C Compiler */ +#if defined(__ARMCC_VERSION) /* ARM C Compiler */ extern const int UtestTcTab$$Base; extern const int UtestTcTab$$Limit; tc_table = (utest_tc_export_t)&UtestTcTab$$Base; diff --git a/components/utilities/var_export/var_export.c b/components/utilities/var_export/var_export.c index f4623dec04..1e54f39362 100644 --- a/components/utilities/var_export/var_export.c +++ b/components/utilities/var_export/var_export.c @@ -20,7 +20,7 @@ static rt_size_t ve_exporter_num = 0; #endif /* for ARM C and IAR Compiler */ -#if defined(__CC_ARM) || defined(__CLANG_ARM) || defined (__ICCARM__) || defined(__ICCRX__) +#if defined(__ARMCC_VERSION) || defined (__ICCARM__) || defined(__ICCRX__) static RT_USED const struct ve_exporter __ve_table_start RT_SECTION("0.""VarExpTab") = {"ve_start", "ve_start", 0}; @@ -43,7 +43,7 @@ RT_USED const struct ve_exporter __ve_table_end = { "ve_end", "ve_end", 2}; int var_export_init(void) { /* initialize the var export table.*/ -#if defined(__CC_ARM) || defined(__CLANG_ARM) /* for ARM C Compiler */ +#if defined(__ARMCC_VERSION) /* for ARM C Compiler */ ve_exporter_table = &__ve_table_start + 1; ve_exporter_num = &__ve_table_end - &__ve_table_start; #elif defined (__GNUC__) /* for GCC Compiler */ @@ -94,7 +94,7 @@ int var_export_init(void) } } ve_exporter_table = ve_exporter_tab; -#endif /* __CC_ARM || __CLANG_ARM */ +#endif /* __ARMCC_VERSION */ return ve_exporter_num; } diff --git a/include/rtdef.h b/include/rtdef.h index b31bd1e3f8..bc133d4271 100644 --- a/include/rtdef.h +++ b/include/rtdef.h @@ -115,10 +115,6 @@ typedef rt_base_t rt_off_t; /**< Type for offset */ #define RT_MB_ENTRY_MAX RT_UINT16_MAX /**< Maxium number of mailbox .entry */ #define RT_MQ_ENTRY_MAX RT_UINT16_MAX /**< Maxium number of message queue .entry */ -#if defined (__ARMCC_VERSION) && (__ARMCC_VERSION >= 6010050) -#define __CLANG_ARM -#endif - #define RT_UNUSED(x) ((void)x) /* Compiler Related Definitions */ diff --git a/libcpu/arm/cortex-m3/cpuport.c b/libcpu/arm/cortex-m3/cpuport.c index d376f00424..66e2aa4809 100644 --- a/libcpu/arm/cortex-m3/cpuport.c +++ b/libcpu/arm/cortex-m3/cpuport.c @@ -385,7 +385,7 @@ __asm int __rt_ffs(int value) exit BX lr } -#elif defined(__CLANG_ARM) +#elif defined(__clang__) int __rt_ffs(int value) { __asm volatile( diff --git a/libcpu/arm/cortex-m33/cpuport.c b/libcpu/arm/cortex-m33/cpuport.c index aa2325012c..71e1fea848 100644 --- a/libcpu/arm/cortex-m33/cpuport.c +++ b/libcpu/arm/cortex-m33/cpuport.c @@ -20,7 +20,7 @@ #include #if /* ARMCC */ ( (defined ( __CC_ARM ) && defined ( __TARGET_FPU_VFP )) \ - /* Clang */ || (defined ( __CLANG_ARM ) && defined ( __VFP_FP__ ) && !defined(__SOFTFP__)) \ + /* Clang */ || (defined ( __clang__ ) && defined ( __VFP_FP__ ) && !defined(__SOFTFP__)) \ /* IAR */ || (defined ( __ICCARM__ ) && defined ( __ARMVFP__ )) \ /* GNU */ || (defined ( __GNUC__ ) && defined ( __VFP_FP__ ) && !defined(__SOFTFP__)) ) #define USE_FPU 1 @@ -472,7 +472,7 @@ __asm int __rt_ffs(int value) exit BX lr } -#elif defined(__CLANG_ARM) +#elif defined(__clang__) int __rt_ffs(int value) { if (value == 0) return value; diff --git a/libcpu/arm/cortex-m33/trustzone.c b/libcpu/arm/cortex-m33/trustzone.c index f49f0c24f8..2cc19a06e4 100644 --- a/libcpu/arm/cortex-m33/trustzone.c +++ b/libcpu/arm/cortex-m33/trustzone.c @@ -37,7 +37,7 @@ static __inline rt_uint32_t __get_IPSR(void) register rt_uint32_t result __asm("ipsr"); return(result); } -#elif defined(__CLANG_ARM) +#elif defined(__clang__) __attribute__((always_inline)) static __inline rt_uint32_t __get_IPSR(void) { rt_uint32_t result; diff --git a/libcpu/arm/cortex-m4/cpuport.c b/libcpu/arm/cortex-m4/cpuport.c index f24c33cf4d..6b748255c5 100644 --- a/libcpu/arm/cortex-m4/cpuport.c +++ b/libcpu/arm/cortex-m4/cpuport.c @@ -20,7 +20,7 @@ #include #if /* ARMCC */ ( (defined ( __CC_ARM ) && defined ( __TARGET_FPU_VFP )) \ - /* Clang */ || (defined ( __CLANG_ARM ) && defined ( __VFP_FP__ ) && !defined(__SOFTFP__)) \ + /* Clang */ || (defined ( __clang__ ) && defined ( __VFP_FP__ ) && !defined(__SOFTFP__)) \ /* IAR */ || (defined ( __ICCARM__ ) && defined ( __ARMVFP__ )) \ /* GNU */ || (defined ( __GNUC__ ) && defined ( __VFP_FP__ ) && !defined(__SOFTFP__)) ) #define USE_FPU 1 @@ -469,7 +469,7 @@ __asm int __rt_ffs(int value) exit BX lr } -#elif defined(__CLANG_ARM) +#elif defined(__clang__) int __rt_ffs(int value) { __asm volatile( diff --git a/libcpu/arm/cortex-m7/cpuport.c b/libcpu/arm/cortex-m7/cpuport.c index f24c33cf4d..6b748255c5 100644 --- a/libcpu/arm/cortex-m7/cpuport.c +++ b/libcpu/arm/cortex-m7/cpuport.c @@ -20,7 +20,7 @@ #include #if /* ARMCC */ ( (defined ( __CC_ARM ) && defined ( __TARGET_FPU_VFP )) \ - /* Clang */ || (defined ( __CLANG_ARM ) && defined ( __VFP_FP__ ) && !defined(__SOFTFP__)) \ + /* Clang */ || (defined ( __clang__ ) && defined ( __VFP_FP__ ) && !defined(__SOFTFP__)) \ /* IAR */ || (defined ( __ICCARM__ ) && defined ( __ARMVFP__ )) \ /* GNU */ || (defined ( __GNUC__ ) && defined ( __VFP_FP__ ) && !defined(__SOFTFP__)) ) #define USE_FPU 1 @@ -469,7 +469,7 @@ __asm int __rt_ffs(int value) exit BX lr } -#elif defined(__CLANG_ARM) +#elif defined(__clang__) int __rt_ffs(int value) { __asm volatile( diff --git a/libcpu/sim/win32/startup.c b/libcpu/sim/win32/startup.c index 756d409315..e3e76323b9 100644 --- a/libcpu/sim/win32/startup.c +++ b/libcpu/sim/win32/startup.c @@ -199,7 +199,7 @@ void rt_application_init(void); void rt_hw_board_init(void); int rtthread_startup(void); -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) extern int $Super$$main(void); /* re-define main function */ int $Sub$$main(void) @@ -248,7 +248,7 @@ void main_thread_entry(void *parameter) rt_hw_secondary_cpu_up(); #endif /* invoke system main function */ -#if defined(__CC_ARM) || defined(__CLANG_ARM) +#if defined(__ARMCC_VERSION) { extern int $Super$$main(void); $Super$$main(); /* for ARMCC. */ From 9c67e061dfba7d53da5795fecedd6285f87fbc48 Mon Sep 17 00:00:00 2001 From: Meco Man <920369182@qq.com> Date: Wed, 29 Dec 2021 22:27:06 -0500 Subject: [PATCH 2/2] [stm32] format codes --- bsp/stm32/stm32f207-st-nucleo/board/board.c | 4 +- bsp/stm32/stm32f207-st-nucleo/board/board.h | 2 +- .../stm32f407-armfly-v5/applications/main.c | 4 +- bsp/stm32/stm32f407-armfly-v5/board/board.c | 10 +-- bsp/stm32/stm32f407-armfly-v5/board/board.h | 4 +- .../stm32f407-armfly-v5/board/ports/fal_cfg.h | 4 +- .../board/ports/sdcard_port.c | 4 +- .../board/ports/spi_flash_init.c | 4 +- .../stm32h750-artpi-h750/applications/main.c | 2 +- .../stm32h750-artpi-h750/board/port/drv_eth.c | 2 +- .../stm32h750-artpi-h750/board/port/drv_eth.h | 2 +- .../board/port/drv_sdio.c | 4 +- .../board/port/drv_sdio.h | 2 +- .../board/port/filesystem.c | 2 +- .../board/port/lcd_port.h | 2 +- .../board/port/lcd_spi_port.h | 2 +- .../board/port/sdram_port.h | 2 +- .../board/port/spi_flash_init.c | 2 +- .../board/port/wifi_config.c | 2 +- .../board/ports/lcd/drv_lcd.c | 6 +- .../board/ports/lcd/drv_lcd_font.h | 2 +- .../stm32l552-st-nucleo/applications/main.c | 2 +- bsp/stm32/stm32l552-st-nucleo/board/board.c | 2 +- bsp/stm32/stm32l552-st-nucleo/board/board.h | 2 +- .../board/ports/drv_sdio.c | 2 +- .../board/ports/crypto_sample.c | 64 +++++++++---------- .../board/ports/dma_sample.c | 2 +- .../stm32u575-st-nucleo/applications/main.c | 2 +- bsp/stm32/stm32u575-st-nucleo/board/board.c | 2 +- bsp/stm32/stm32u575-st-nucleo/board/board.h | 2 +- bsp/stm32/stm32wb55-st-nucleo/board/board.c | 2 +- 31 files changed, 75 insertions(+), 75 deletions(-) diff --git a/bsp/stm32/stm32f207-st-nucleo/board/board.c b/bsp/stm32/stm32f207-st-nucleo/board/board.c index efc28d32e8..cd22eb8a57 100644 --- a/bsp/stm32/stm32f207-st-nucleo/board/board.c +++ b/bsp/stm32/stm32f207-st-nucleo/board/board.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * @@ -7,7 +7,7 @@ * Date Author Notes * 2018-11-06 SummerGift first version */ - + #include "board.h" void SystemClock_Config(void) diff --git a/bsp/stm32/stm32f207-st-nucleo/board/board.h b/bsp/stm32/stm32f207-st-nucleo/board/board.h index b7b40bb799..c52bed558b 100644 --- a/bsp/stm32/stm32f207-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f207-st-nucleo/board/board.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * diff --git a/bsp/stm32/stm32f407-armfly-v5/applications/main.c b/bsp/stm32/stm32f407-armfly-v5/applications/main.c index 297573866c..f7ace7aa57 100644 --- a/bsp/stm32/stm32f407-armfly-v5/applications/main.c +++ b/bsp/stm32/stm32f407-armfly-v5/applications/main.c @@ -1,10 +1,10 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * * Change Logs: - * Date Author Notes + * Date Author Notes * 2020-07-13 Dozingfiretruck first version */ diff --git a/bsp/stm32/stm32f407-armfly-v5/board/board.c b/bsp/stm32/stm32f407-armfly-v5/board/board.c index e64882e5e1..89a7fdc26a 100644 --- a/bsp/stm32/stm32f407-armfly-v5/board/board.c +++ b/bsp/stm32/stm32f407-armfly-v5/board/board.c @@ -1,10 +1,10 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * * Change Logs: - * Date Author Notes + * Date Author Notes * 2020-07-13 Dozingfiretruck first version */ @@ -16,11 +16,11 @@ void SystemClock_Config(void) RCC_ClkInitTypeDef RCC_ClkInitStruct = {0}; RCC_PeriphCLKInitTypeDef PeriphClkInitStruct = {0}; - /** Configure the main internal regulator output voltage + /** Configure the main internal regulator output voltage */ __HAL_RCC_PWR_CLK_ENABLE(); __HAL_PWR_VOLTAGESCALING_CONFIG(PWR_REGULATOR_VOLTAGE_SCALE1); - /** Initializes the CPU, AHB and APB busses clocks + /** Initializes the CPU, AHB and APB busses clocks */ RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_LSI|RCC_OSCILLATORTYPE_HSE |RCC_OSCILLATORTYPE_LSE; @@ -37,7 +37,7 @@ void SystemClock_Config(void) { Error_Handler(); } - /** Initializes the CPU, AHB and APB busses clocks + /** Initializes the CPU, AHB and APB busses clocks */ RCC_ClkInitStruct.ClockType = RCC_CLOCKTYPE_HCLK|RCC_CLOCKTYPE_SYSCLK |RCC_CLOCKTYPE_PCLK1|RCC_CLOCKTYPE_PCLK2; diff --git a/bsp/stm32/stm32f407-armfly-v5/board/board.h b/bsp/stm32/stm32f407-armfly-v5/board/board.h index 00108ee123..995b482f86 100644 --- a/bsp/stm32/stm32f407-armfly-v5/board/board.h +++ b/bsp/stm32/stm32f407-armfly-v5/board/board.h @@ -1,10 +1,10 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * * Change Logs: - * Date Author Notes + * Date Author Notes * 2020-07-13 Dozingfiretruck first version */ diff --git a/bsp/stm32/stm32f407-armfly-v5/board/ports/fal_cfg.h b/bsp/stm32/stm32f407-armfly-v5/board/ports/fal_cfg.h index 20bcf9e11a..c512fcef35 100644 --- a/bsp/stm32/stm32f407-armfly-v5/board/ports/fal_cfg.h +++ b/bsp/stm32/stm32f407-armfly-v5/board/ports/fal_cfg.h @@ -1,10 +1,10 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * * Change Logs: - * Date Author Notes + * Date Author Notes * 2020-07-13 Dozingfiretruck first version */ diff --git a/bsp/stm32/stm32f407-armfly-v5/board/ports/sdcard_port.c b/bsp/stm32/stm32f407-armfly-v5/board/ports/sdcard_port.c index 5eead223c3..f5427ef265 100644 --- a/bsp/stm32/stm32f407-armfly-v5/board/ports/sdcard_port.c +++ b/bsp/stm32/stm32f407-armfly-v5/board/ports/sdcard_port.c @@ -1,10 +1,10 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * * Change Logs: - * Date Author Notes + * Date Author Notes * 2020-07-13 Dozingfiretruck first version */ diff --git a/bsp/stm32/stm32f407-armfly-v5/board/ports/spi_flash_init.c b/bsp/stm32/stm32f407-armfly-v5/board/ports/spi_flash_init.c index 9aa8f95c13..3f879fdfbc 100644 --- a/bsp/stm32/stm32f407-armfly-v5/board/ports/spi_flash_init.c +++ b/bsp/stm32/stm32f407-armfly-v5/board/ports/spi_flash_init.c @@ -1,10 +1,10 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * * Change Logs: - * Date Author Notes + * Date Author Notes * 2020-07-13 Dozingfiretruck first version */ diff --git a/bsp/stm32/stm32h750-artpi-h750/applications/main.c b/bsp/stm32/stm32h750-artpi-h750/applications/main.c index a44353b41f..a647d2cdf1 100644 --- a/bsp/stm32/stm32h750-artpi-h750/applications/main.c +++ b/bsp/stm32/stm32h750-artpi-h750/applications/main.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * diff --git a/bsp/stm32/stm32h750-artpi-h750/board/port/drv_eth.c b/bsp/stm32/stm32h750-artpi-h750/board/port/drv_eth.c index e50dca5398..30c9659c50 100644 --- a/bsp/stm32/stm32h750-artpi-h750/board/port/drv_eth.c +++ b/bsp/stm32/stm32h750-artpi-h750/board/port/drv_eth.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * diff --git a/bsp/stm32/stm32h750-artpi-h750/board/port/drv_eth.h b/bsp/stm32/stm32h750-artpi-h750/board/port/drv_eth.h index fd8e86cf3c..5e5331f6eb 100644 --- a/bsp/stm32/stm32h750-artpi-h750/board/port/drv_eth.h +++ b/bsp/stm32/stm32h750-artpi-h750/board/port/drv_eth.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * diff --git a/bsp/stm32/stm32h750-artpi-h750/board/port/drv_sdio.c b/bsp/stm32/stm32h750-artpi-h750/board/port/drv_sdio.c index 5581dfe792..f8d473e426 100644 --- a/bsp/stm32/stm32h750-artpi-h750/board/port/drv_sdio.c +++ b/bsp/stm32/stm32h750-artpi-h750/board/port/drv_sdio.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2020, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * @@ -534,4 +534,4 @@ void sdcard_change(void) mmcsd_change(host1); } -#endif /* RT_USING_SDIO */ \ No newline at end of file +#endif /* RT_USING_SDIO */ diff --git a/bsp/stm32/stm32h750-artpi-h750/board/port/drv_sdio.h b/bsp/stm32/stm32h750-artpi-h750/board/port/drv_sdio.h index e3c6ac0659..32eb3e0919 100644 --- a/bsp/stm32/stm32h750-artpi-h750/board/port/drv_sdio.h +++ b/bsp/stm32/stm32h750-artpi-h750/board/port/drv_sdio.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2020, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * diff --git a/bsp/stm32/stm32h750-artpi-h750/board/port/filesystem.c b/bsp/stm32/stm32h750-artpi-h750/board/port/filesystem.c index d45c04f2f6..7e181ecdfe 100644 --- a/bsp/stm32/stm32h750-artpi-h750/board/port/filesystem.c +++ b/bsp/stm32/stm32h750-artpi-h750/board/port/filesystem.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * diff --git a/bsp/stm32/stm32h750-artpi-h750/board/port/lcd_port.h b/bsp/stm32/stm32h750-artpi-h750/board/port/lcd_port.h index e8997e61ea..ea745cdbec 100644 --- a/bsp/stm32/stm32h750-artpi-h750/board/port/lcd_port.h +++ b/bsp/stm32/stm32h750-artpi-h750/board/port/lcd_port.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * diff --git a/bsp/stm32/stm32h750-artpi-h750/board/port/lcd_spi_port.h b/bsp/stm32/stm32h750-artpi-h750/board/port/lcd_spi_port.h index 213f9e6d1d..3957c3a355 100644 --- a/bsp/stm32/stm32h750-artpi-h750/board/port/lcd_spi_port.h +++ b/bsp/stm32/stm32h750-artpi-h750/board/port/lcd_spi_port.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * diff --git a/bsp/stm32/stm32h750-artpi-h750/board/port/sdram_port.h b/bsp/stm32/stm32h750-artpi-h750/board/port/sdram_port.h index 5784f79036..50804561eb 100644 --- a/bsp/stm32/stm32h750-artpi-h750/board/port/sdram_port.h +++ b/bsp/stm32/stm32h750-artpi-h750/board/port/sdram_port.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * diff --git a/bsp/stm32/stm32h750-artpi-h750/board/port/spi_flash_init.c b/bsp/stm32/stm32h750-artpi-h750/board/port/spi_flash_init.c index bee31fe39a..2a27633e13 100644 --- a/bsp/stm32/stm32h750-artpi-h750/board/port/spi_flash_init.c +++ b/bsp/stm32/stm32h750-artpi-h750/board/port/spi_flash_init.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * diff --git a/bsp/stm32/stm32h750-artpi-h750/board/port/wifi_config.c b/bsp/stm32/stm32h750-artpi-h750/board/port/wifi_config.c index b28573d04a..256739de07 100644 --- a/bsp/stm32/stm32h750-artpi-h750/board/port/wifi_config.c +++ b/bsp/stm32/stm32h750-artpi-h750/board/port/wifi_config.c @@ -260,4 +260,4 @@ void wlan_autoconnect_init(void) rt_wlan_cfg_cache_refresh(); } -#endif \ No newline at end of file +#endif diff --git a/bsp/stm32/stm32l431-BearPi/board/ports/lcd/drv_lcd.c b/bsp/stm32/stm32l431-BearPi/board/ports/lcd/drv_lcd.c index 6150a5b184..23f9c14cc1 100644 --- a/bsp/stm32/stm32l431-BearPi/board/ports/lcd/drv_lcd.c +++ b/bsp/stm32/stm32l431-BearPi/board/ports/lcd/drv_lcd.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * @@ -202,7 +202,7 @@ static int rt_hw_lcd_init(void) rt_thread_mdelay(100); lcd_clear(WHITE); - lcd_show_string(0, 0, 32, "RT-Thread"); + lcd_show_string(0, 0, 32, "RT-Thread"); /* display on */ rt_pin_write(LCD_PWR_PIN, PIN_HIGH); @@ -818,4 +818,4 @@ rt_err_t lcd_show_image(rt_uint16_t x, rt_uint16_t y, rt_uint16_t length, rt_uin rt_spi_send(spi_dev_lcd, p, length * wide * 2); return RT_EOK; -} \ No newline at end of file +} diff --git a/bsp/stm32/stm32l431-BearPi/board/ports/lcd/drv_lcd_font.h b/bsp/stm32/stm32l431-BearPi/board/ports/lcd/drv_lcd_font.h index f37721ba03..0f095de929 100644 --- a/bsp/stm32/stm32l431-BearPi/board/ports/lcd/drv_lcd_font.h +++ b/bsp/stm32/stm32l431-BearPi/board/ports/lcd/drv_lcd_font.h @@ -1,5 +1,5 @@ #ifndef __DRV_LCD_FONT_H__ -#define __DRV_LCD_FONT_H__ +#define __DRV_LCD_FONT_H__ #include #define ASC2_1608 diff --git a/bsp/stm32/stm32l552-st-nucleo/applications/main.c b/bsp/stm32/stm32l552-st-nucleo/applications/main.c index 02a87cce8c..4934636f4b 100644 --- a/bsp/stm32/stm32l552-st-nucleo/applications/main.c +++ b/bsp/stm32/stm32l552-st-nucleo/applications/main.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * diff --git a/bsp/stm32/stm32l552-st-nucleo/board/board.c b/bsp/stm32/stm32l552-st-nucleo/board/board.c index 5123872136..bc2807f8ce 100644 --- a/bsp/stm32/stm32l552-st-nucleo/board/board.c +++ b/bsp/stm32/stm32l552-st-nucleo/board/board.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * diff --git a/bsp/stm32/stm32l552-st-nucleo/board/board.h b/bsp/stm32/stm32l552-st-nucleo/board/board.h index 479a4262fb..daf0a205fe 100644 --- a/bsp/stm32/stm32l552-st-nucleo/board/board.h +++ b/bsp/stm32/stm32l552-st-nucleo/board/board.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * diff --git a/bsp/stm32/stm32mp157a-st-discovery/board/ports/drv_sdio.c b/bsp/stm32/stm32mp157a-st-discovery/board/ports/drv_sdio.c index 21d207c24c..54f84b59b4 100644 --- a/bsp/stm32/stm32mp157a-st-discovery/board/ports/drv_sdio.c +++ b/bsp/stm32/stm32mp157a-st-discovery/board/ports/drv_sdio.c @@ -579,7 +579,7 @@ int rt_hw_sdio_init(void) #endif #ifdef BSP_USING_SDIO2 - + if (IS_ENGINEERING_BOOT_MODE()) { MX_RTC_Init(); diff --git a/bsp/stm32/stm32mp157a-st-ev1/board/ports/crypto_sample.c b/bsp/stm32/stm32mp157a-st-ev1/board/ports/crypto_sample.c index fcad8fb9ff..0d2c599ebe 100644 --- a/bsp/stm32/stm32mp157a-st-ev1/board/ports/crypto_sample.c +++ b/bsp/stm32/stm32mp157a-st-ev1/board/ports/crypto_sample.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2022, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * @@ -43,7 +43,7 @@ static void hw_crc_sample(uint8_t *temp, int size) { struct rt_hwcrypto_ctx *ctx; rt_uint32_t result = 0; - + struct hwcrypto_crc_cfg cfg = { .last_val = 0xFFFFFFFF, @@ -58,9 +58,9 @@ static void hw_crc_sample(uint8_t *temp, int size) result = rt_hwcrypto_crc_update(ctx, temp, size); - rt_kprintf("crc result: %x \n", result); + rt_kprintf("crc result: %x \n", result); - rt_hwcrypto_crc_destroy(ctx); + rt_hwcrypto_crc_destroy(ctx); } #endif @@ -70,19 +70,19 @@ static void hw_hash_sample() int i = 0; struct rt_hwcrypto_ctx *ctx = RT_NULL; const uint8_t hash_input[] = "RT-Thread was born in 2006, it is an open source, neutral, and community-based real-time operating system (RTOS)."; - + static uint8_t sha1_output[20]; - static uint8_t sha1_except[20] = {0xff, 0x3c, 0x95, 0x54, 0x95, 0xf0, 0xad, + static uint8_t sha1_except[20] = {0xff, 0x3c, 0x95, 0x54, 0x95, 0xf0, 0xad, 0x02, 0x1b, 0xa8, 0xbc, 0xa2, 0x2e, 0xa5, 0xb0, 0x62, 0x1b, 0xdf, 0x7f, 0xec}; - + static uint8_t md5_output[16]; - static uint8_t md5_except[16] = {0x40, 0x86, 0x03, 0x80, 0x0d, 0x8c, 0xb9, + static uint8_t md5_except[16] = {0x40, 0x86, 0x03, 0x80, 0x0d, 0x8c, 0xb9, 0x4c, 0xd6, 0x7d, 0x28, 0xfc, 0xf6, 0xc3, 0xac, 0x8b}; - + static uint8_t sha224_output[28]; - static uint8_t sha224_except[28] = {0x6f, 0x62, 0x52, 0x7d, 0x80, 0xe6, + static uint8_t sha224_except[28] = {0x6f, 0x62, 0x52, 0x7d, 0x80, 0xe6, 0x9f, 0x82, 0x78, 0x7a, 0x46, 0x91, 0xb0, 0xe9, 0x64, 0x89, 0xe6, 0xc3, 0x6b, 0x7e, 0xcf, 0xca, 0x11, 0x42, @@ -101,7 +101,7 @@ static void hw_hash_sample() rt_kprintf("%c", hash_input[i]); } rt_kprintf("\n"); - + /* sh1 test*/ ctx = rt_hwcrypto_hash_create(rt_hwcrypto_dev_default(), HWCRYPTO_TYPE_SHA1); if (ctx == RT_NULL) @@ -114,13 +114,13 @@ static void hw_hash_sample() for (i = 0; i < sizeof(sha1_except); i++) { rt_kprintf("%x ", sha1_except[i]); - } + } rt_kprintf("\n"); /* start sha1 */ rt_hwcrypto_hash_update(ctx, hash_input, rt_strlen((char const *)hash_input)); /* get sha1 result */ rt_hwcrypto_hash_finish(ctx, sha1_output, rt_strlen((char const *)sha1_output)); - + rt_kprintf("Actual sha1 result: \n"); for (i = 0; i < sizeof(sha1_output); i++) { @@ -137,7 +137,7 @@ static void hw_hash_sample() } /* deinit hash*/ rt_hwcrypto_hash_destroy(ctx); - + /* md5 test*/ ctx = rt_hwcrypto_hash_create(rt_hwcrypto_dev_default(), HWCRYPTO_TYPE_MD5); if (ctx == RT_NULL) @@ -150,13 +150,13 @@ static void hw_hash_sample() for (i = 0; i < sizeof(md5_except); i++) { rt_kprintf("%x ", md5_except[i]); - } + } rt_kprintf("\n"); /* start md5 */ rt_hwcrypto_hash_update(ctx, hash_input, rt_strlen((char const *)hash_input)); /* get md5 result */ rt_hwcrypto_hash_finish(ctx, md5_output, rt_strlen((char const *)md5_output)); - + rt_kprintf("Actual md5 result: \n"); for (i = 0; i < sizeof(md5_output); i++) { @@ -173,7 +173,7 @@ static void hw_hash_sample() } /* deinit hash*/ rt_hwcrypto_hash_destroy(ctx); - + /* sha224 test */ ctx = rt_hwcrypto_hash_create(rt_hwcrypto_dev_default(), HWCRYPTO_TYPE_SHA224); if (ctx == RT_NULL) @@ -186,13 +186,13 @@ static void hw_hash_sample() for (i = 0; i < sizeof(sha224_except); i++) { rt_kprintf("%x ", sha224_except[i]); - } + } rt_kprintf("\n"); /* start sha224 */ rt_hwcrypto_hash_update(ctx, hash_input, rt_strlen((char const *)hash_input)); /* get sha224 result */ rt_hwcrypto_hash_finish(ctx, sha224_output, rt_strlen((char const *)sha224_output)); - + rt_kprintf("Actual sha224 result: \n"); for (i = 0; i < sizeof(sha224_output); i++) { @@ -216,13 +216,13 @@ static void hw_hash_sample() rt_kprintf("create hash[%08x] context err!\n", HWCRYPTO_TYPE_SHA256); return ; } - + rt_kprintf("Create sha256 type success!\n"); rt_kprintf("Except sha256 result: \n"); for (i = 0; i < sizeof(sha256_except); i++) { rt_kprintf("%x ", sha256_except[i]); - } + } rt_kprintf("\n"); /* start sha256 */ rt_hwcrypto_hash_update(ctx, hash_input, rt_strlen((char const *)hash_input)); @@ -235,7 +235,7 @@ static void hw_hash_sample() rt_kprintf("%x ", sha256_output[i]); } rt_kprintf("\n"); - + if(rt_memcmp(sha256_output, sha256_except, sizeof(sha256_except)/sizeof(sha256_except[0])) != 0) { rt_kprintf("Hash type sha256 Test error, The actual result is not equal to the except result\n"); @@ -245,7 +245,7 @@ static void hw_hash_sample() rt_kprintf("Hash type sha256 Test success, The actual result is equal to the except result\n"); } rt_hwcrypto_hash_destroy(ctx); - rt_kprintf("Hash Test over!\n"); + rt_kprintf("Hash Test over!\n"); } #endif @@ -254,7 +254,7 @@ static int crypto(int argc, char **argv) int result = RT_EOK; static rt_device_t device = RT_NULL; char *result_str; - + if (argc > 1) { if (!strcmp(argv[1], "probe")) @@ -293,7 +293,7 @@ static int crypto(int argc, char **argv) { rt_kprintf("rng - generate digital\n"); } - + #else rt_kprintf("please enable RNG first!\n"); #endif @@ -301,7 +301,7 @@ static int crypto(int argc, char **argv) else if (!strcmp(argv[1], "crc")) { #if defined (BSP_USING_CRC) - int size = 0, i = 0; + int size = 0, i = 0; if (argc > 3) { size = argc - 2; @@ -312,7 +312,7 @@ static int crypto(int argc, char **argv) { data[i] = strtol(argv[2 + i], NULL, 0); } - hw_crc_sample(data, size); + hw_crc_sample(data, size); rt_free(data); } else @@ -333,16 +333,16 @@ static int crypto(int argc, char **argv) #if defined (BSP_USING_HASH) if (argc == 3) { - hw_hash_sample(); + hw_hash_sample(); } else { - rt_kprintf("crypto hash sample - hash use sample\n"); + rt_kprintf("crypto hash sample - hash use sample\n"); } #else - rt_kprintf("please enable CRC first!\n"); + rt_kprintf("please enable CRC first!\n"); #endif - + } else { @@ -359,7 +359,7 @@ static int crypto(int argc, char **argv) rt_kprintf("crypto hash sample - hash use sample\n"); result = -RT_ERROR; } - + return result; } MSH_CMD_EXPORT(crypto, crypto function); diff --git a/bsp/stm32/stm32mp157a-st-ev1/board/ports/dma_sample.c b/bsp/stm32/stm32mp157a-st-ev1/board/ports/dma_sample.c index 4a269bf936..0e3aabe37e 100644 --- a/bsp/stm32/stm32mp157a-st-ev1/board/ports/dma_sample.c +++ b/bsp/stm32/stm32mp157a-st-ev1/board/ports/dma_sample.c @@ -34,7 +34,7 @@ static rt_err_t uart_input(rt_device_t dev, rt_size_t size) result = rt_mq_send(&rx_mq, &msg, sizeof(msg)); if ( result == -RT_EFULL) { - rt_kprintf("message queue full!\n"); + rt_kprintf("message queue full!\n"); } return result; } diff --git a/bsp/stm32/stm32u575-st-nucleo/applications/main.c b/bsp/stm32/stm32u575-st-nucleo/applications/main.c index b90ee2e99d..54a2644064 100644 --- a/bsp/stm32/stm32u575-st-nucleo/applications/main.c +++ b/bsp/stm32/stm32u575-st-nucleo/applications/main.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * diff --git a/bsp/stm32/stm32u575-st-nucleo/board/board.c b/bsp/stm32/stm32u575-st-nucleo/board/board.c index f472d5ae51..069f9ed3a1 100644 --- a/bsp/stm32/stm32u575-st-nucleo/board/board.c +++ b/bsp/stm32/stm32u575-st-nucleo/board/board.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * diff --git a/bsp/stm32/stm32u575-st-nucleo/board/board.h b/bsp/stm32/stm32u575-st-nucleo/board/board.h index 21566e54c8..4902fbe8fb 100644 --- a/bsp/stm32/stm32u575-st-nucleo/board/board.h +++ b/bsp/stm32/stm32u575-st-nucleo/board/board.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * diff --git a/bsp/stm32/stm32wb55-st-nucleo/board/board.c b/bsp/stm32/stm32wb55-st-nucleo/board/board.c index 11c7c8cf2b..5058b6e8a2 100644 --- a/bsp/stm32/stm32wb55-st-nucleo/board/board.c +++ b/bsp/stm32/stm32wb55-st-nucleo/board/board.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 *