From 3084d15821f27b7f8022ec1c78d7aa53298deaf7 Mon Sep 17 00:00:00 2001 From: Martino Facchin Date: Wed, 28 Oct 2020 15:37:13 +0100 Subject: [PATCH] STM32H7: DualCore: allow no forced CM4 boot --- targets/TARGET_STM/mbed_overrides.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/targets/TARGET_STM/mbed_overrides.c b/targets/TARGET_STM/mbed_overrides.c index 22d50dd96b..3f13af5d9d 100644 --- a/targets/TARGET_STM/mbed_overrides.c +++ b/targets/TARGET_STM/mbed_overrides.c @@ -252,6 +252,7 @@ void mbed_sdk_init() SetSysClock(); SystemCoreClockUpdate(); +#ifndef CM4_BOOT_BY_APPLICATION /* Check wether CM4 boot in parallel with CM7. If CM4 was gated but CM7 trigger the CM4 boot. No need to wait for synchronization. otherwise CM7 should wakeup CM4 when system clocks initialization is done. */ if (READ_BIT(SYSCFG->UR1, SYSCFG_UR1_BCM4)) { @@ -263,6 +264,7 @@ void mbed_sdk_init() } /* wait until CPU2 wakes up from stop mode */ while (LL_RCC_D2CK_IsReady() == 0); +#endif /* CM4_BOOT_BY_APPLICATION */ #endif /* CORE_M4 */ #else /* Single core */