From 52211471c2debc9878ff76057db0dc4b7a7ea64d Mon Sep 17 00:00:00 2001 From: Gerard Swiderski Date: Wed, 12 Jul 2023 14:37:37 +0200 Subject: [PATCH] armv7m: Change cpuReset logic in exceptions JIRA: RTOS-520 --- hal/armv7m/exceptions.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/hal/armv7m/exceptions.c b/hal/armv7m/exceptions.c index dc6605d9..68b74843 100644 --- a/hal/armv7m/exceptions.c +++ b/hal/armv7m/exceptions.c @@ -130,12 +130,8 @@ __attribute__((section(".noxip"))) void hal_exceptionsDispatch(unsigned int n, s hal_exceptionsDumpContext(buff, ctx, n); hal_consolePrint(buff); -#ifdef NDEBUG -#ifdef CPU_STM32 - _stm32_nvicSystemReset(); -#elif defined(CPU_IMXRT) - _imxrt_nvicSystemReset(); -#endif +#ifndef NDEBUG + hal_cpuReset(); #endif for (;;) {