1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-12-25 22:43:50 +01:00

cpu/stm32f1: fix flashpage driver HSI disabling

This commit is contained in:
Vincent Dupont 2017-01-24 15:08:32 +01:00
parent e5a1c7835f
commit 54dc75d63c

View File

@ -81,7 +81,7 @@ void flashpage_write(int page, void *data)
FLASH->CR |= FLASH_CR_LOCK;
/* restore the HSI state */
if (hsi_state) {
if (!hsi_state) {
RCC->CR &= ~(RCC_CR_HSION);
while (RCC->CR & RCC_CR_HSIRDY) {}
}