stm32f4: reset peripheral clocks on init

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
This commit is contained in:
Eric Callahan authored and KevinOConnor committed 2021-11-08 20:10:51 -05:00
1 parent 76bfc3237a
commit bf9d497ab0
1 file changed
+6
+6
View File
@@ -260,6 +260,12 @@ armcm_main(void)
SystemInit();
SCB->VTOR = (uint32_t)VectorTable;
// Reset peripheral clocks (for some bootloaders that don't)
RCC->AHB1ENR = 0x38000;
RCC->AHB2ENR = 0;
RCC->APB1ENR = 0;
RCC->APB2ENR = 0;
clock_setup();
sched_main();