From 8cbcdd71ec4ec02d241dc22fa11b894ff26b7d27 Mon Sep 17 00:00:00 2001 From: Wayne Ren Date: Tue, 13 Aug 2019 17:16:55 +0800 Subject: [PATCH] arch: arc: secure stat should also be reset correctly secure status should aslo be set correctly Signed-off-by: Wayne Ren --- arch/arc/core/reset.S | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/arch/arc/core/reset.S b/arch/arc/core/reset.S index 37943acd605..720bfc570c8 100644 --- a/arch/arc/core/reset.S +++ b/arch/arc/core/reset.S @@ -50,6 +50,11 @@ SECTION_FUNC(TEXT,__start) */ mov r0, 0 kflag r0 + +#ifdef CONFIG_ARC_SECURE_FIRMWARE + sflag r0 +#endif + #if defined(CONFIG_BOOT_TIME_MEASUREMENT) && defined(CONFIG_ARCV2_TIMER) /* * ARCV2 timer (timer0) is a free run timer, let it start to count @@ -68,8 +73,6 @@ SECTION_FUNC(TEXT,__start) #endif sr r0, [_ARC_V2_AUX_IRQ_HINT] - /* \todo: MPU init, gp for small data? */ - /* set the vector table base early, * so that exception vectors can be handled. */