summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDamien George <damien@micropython.org>2021-09-02 13:03:47 +1000
committerDamien George <damien@micropython.org>2021-09-02 20:28:53 +1000
commit9792c9105f13f8d0196677e3e4bf003a96998c7b (patch)
tree46109101197a00c4ac42a76df67241dc7e29d136
parent05cd17e36fbc5d3606e34e430dc72549bd1d6708 (diff)
stm32/main: Don't unconditionally enable GPIO A,B,C,D clocks.
Rely on them being enabled only when needed. Signed-off-by: Damien George <damien@micropython.org>
-rw-r--r--ports/stm32/main.c8
1 files changed, 0 insertions, 8 deletions
diff --git a/ports/stm32/main.c b/ports/stm32/main.c
index d55f1a2c3..ccc8fd1ae 100644
--- a/ports/stm32/main.c
+++ b/ports/stm32/main.c
@@ -369,14 +369,6 @@ void stm32_main(uint32_t reset_mode) {
// set the system clock to be HSE
SystemClock_Config();
- // enable GPIO clocks
- __HAL_RCC_GPIOA_CLK_ENABLE();
- __HAL_RCC_GPIOB_CLK_ENABLE();
- __HAL_RCC_GPIOC_CLK_ENABLE();
- #if defined(GPIOD)
- __HAL_RCC_GPIOD_CLK_ENABLE();
- #endif
-
#if defined(STM32F4) || defined(STM32F7)
#if defined(__HAL_RCC_DTCMRAMEN_CLK_ENABLE)
// The STM32F746 doesn't really have CCM memory, but it does have DTCM,