From 97dd30227da602a3b4ae513ecebafda9450edb86 Mon Sep 17 00:00:00 2001 From: Chun-Chieh Li Date: Fri, 14 Jun 2019 18:07:57 +0800 Subject: [PATCH] M23: Fix compile error with mbed fault handler M23 doesn't implement Main Extension. So like M0/M0+, these registers HFSR/ MMFSR/BFSR/UFSR/DFSR are not present on M23. Remove access to them in mbed fault handler for M23 targets. --- platform/TARGET_CORTEX_M/mbed_fault_handler.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform/TARGET_CORTEX_M/mbed_fault_handler.c b/platform/TARGET_CORTEX_M/mbed_fault_handler.c index 9a391f766f..36a0256618 100644 --- a/platform/TARGET_CORTEX_M/mbed_fault_handler.c +++ b/platform/TARGET_CORTEX_M/mbed_fault_handler.c @@ -98,7 +98,7 @@ MBED_NOINLINE void print_context_info(void) //Capture CPUID to get core/cpu info mbed_error_printf("\nCPUID: %08" PRIX32, SCB->CPUID); -#if !defined(TARGET_M0) && !defined(TARGET_M0P) +#if !defined(TARGET_M0) && !defined(TARGET_M0P) && !defined(TARGET_M23) //Capture fault information registers to infer the cause of exception mbed_error_printf("\nHFSR : %08" PRIX32 "\nMMFSR: %08" PRIX32