diff --git a/arch/arm/src/stm32/stm32f40xxx_rtcc.c b/arch/arm/src/stm32/stm32f40xxx_rtcc.c index 0f38fcff53..cf584bea57 100644 --- a/arch/arm/src/stm32/stm32f40xxx_rtcc.c +++ b/arch/arm/src/stm32/stm32f40xxx_rtcc.c @@ -1444,16 +1444,6 @@ int stm32_rtc_cancelalarm(enum alm_id_e alarmid) rtc_wprunlock(); -#if 0 - /* Set Initialization mode */ - - ret = rtc_enterinit(); - if (ret < 0) - { - goto errout_with_wprunlock; - } -#endif - /* Disable RTC alarm and interrupt */ modifyreg32(STM32_RTC_CR, (RTC_CR_ALRAE | RTC_CR_ALRAIE), 0); @@ -1485,16 +1475,6 @@ int stm32_rtc_cancelalarm(enum alm_id_e alarmid) rtc_wprunlock(); -#if 0 - /* Set Initialization mode */ - - ret = rtc_enterinit(); - if (ret < 0) - { - goto errout_with_wprunlock; - } -#endif - /* Disable RTC alarm and interrupt */ modifyreg32(STM32_RTC_CR, (RTC_CR_ALRBE | RTC_CR_ALRBIE), 0);