/* Perform basic hardware initialization at boot. 
This needs to be run from the very beginning. So the init priority has to be 0 (zero). */
static int stm32h7_m4_init(void)
/* Perform basic hardware initialization at boot. 
This needs to be run from the very beginning. So the init priority has to be 0 (zero). */
static int stm32h7_m4_init(void)
{
	LL_AHB1_GRP1_EnableClock(LL_AHB1_GRP1_PERIPH_ART);
	LL_ART_SetBaseAddress(DT_REG_ADDR(DT_CHOSEN(zephyr_flash)));
	LL_ART_Enable();
	if (!LL_RCC_IsCM4BootForced()) {
		LL_AHB4_GRP1_EnableClock(LL_AHB4_GRP1_PERIPH_HSEM);
		while ((HSEM->RLR[CFG_HW_ENTRY_STOP_MODE_SEMID] & HSEM_R_LOCK)
				!= HSEM_R_LOCK)
			;
	}
	return 0;
}