Skip to content

Commit f32765e

Browse files
committed
Build: Fix IAR build Error
Without these fixes IAR build is failing. Change-Id: Id854cd4009c9a23cb9fd4593845f2b4f1c05bd6f Signed-off-by: Michel Jaouen <[email protected]>
1 parent 73f6005 commit f32765e

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

platform/ext/common/boot_hal_bl2.c

+11
Original file line numberDiff line numberDiff line change
@@ -37,14 +37,25 @@ REGION_DECLARE(Image$$, ARM_LIB_HEAP, $$ZI$$Limit)[];
3737
REGION_DECLARE(Image$$, ARM_LIB_STACK, $$ZI$$Base);
3838
#endif /* defined(__ARM_ARCH_8M_MAIN__) || defined(__ARM_ARCH_8M_BASE__) \
3939
|| defined(__ARM_ARCH_8_1M_MAIN__) */
40+
#if defined(__ICCARM__)
41+
#pragma required = ER_DATA$$Base
42+
#pragma required = ARM_LIB_HEAP$$Limit
43+
#endif
4044

4145
__WEAK __attribute__((naked)) void boot_clear_ram_area(void)
4246
{
4347
__ASM volatile(
48+
#if !defined(__ICCARM__)
4449
".syntax unified \n"
50+
#endif
4551
"movs r0, #0 \n"
52+
#if !defined(__ICCARM__)
4653
"ldr r1, =Image$$ER_DATA$$Base \n"
4754
"ldr r2, =Image$$ARM_LIB_HEAP$$ZI$$Limit \n"
55+
#else
56+
"ldr r1, =ER_DATA$$Base \n"
57+
"ldr r2, =ARM_LIB_HEAP$$Limit \n"
58+
#endif
4859
"subs r2, r2, r1 \n"
4960
"Loop: \n"
5061
"subs r2, #4 \n"

secure_fw/spm/cmsis_func/arch.c

+1
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
#include "tfm_secure_api.h"
1111

1212
#if defined(__ICCARM__)
13+
#include "cmsis_psa/tfm_svcalls.h"
1314
#pragma required = tfm_core_svc_handler
1415
#endif
1516

0 commit comments

Comments
 (0)