• Clayton Mills's avatar
    stm32/powerctrl: Disable sys tick interrupt in stop mode on some STM32s. · 0d8d9119
    Clayton Mills authored
    According to ST Errata ES0206 Rev 18, Section 2.2.1, on STM32F427x,
    STM32F437x, STM32F429x and STM32F439x.
    
    If the system tick interrupt is enabled during stop mode while certain
    bits are set in the DBGMCU_CR, then the system will immediately wake
    from stop mode.
    
    Suggested workaround is to disable system tick timer interrupt when
    entering stop mode.
    
    According to ST Errate ES0394 Rev 11, Section 2.2.17, on STM32WB55Cx and
    STM32WB35Cx.
    
    If the system tick interrupt is enabled during stop 0, stop 1 or stop 2
    while certain bits are set in DBGMCU_CR, then system will immediately
    wake from stop mode but the system remains in low power state. The CPU
    therefore fetches incorrect data from inactive Flash, which can cause a
    hard fault.
    
    Suggested workaround is to disable system tick timer interrupt when
    entering stop mode.
    0d8d9119
powerctrl.c 32.1 KB