aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGiovanni Di Sirio <gdisirio@gmail.com>2017-03-26 12:51:38 +0000
committerGiovanni Di Sirio <gdisirio@gmail.com>2017-03-26 12:51:38 +0000
commitfdf3721c1d496ca341b2ea6e41f31d1ecff287b4 (patch)
tree35849ff1acb2f4a9be452ecbd43cef1d747cf603
parentbea80e41e5a987d95d6c72e37611f8d06a1e4268 (diff)
downloadChibiOS-fdf3721c1d496ca341b2ea6e41f31d1ecff287b4.tar.gz
ChibiOS-fdf3721c1d496ca341b2ea6e41f31d1ecff287b4.tar.bz2
ChibiOS-fdf3721c1d496ca341b2ea6e41f31d1ecff287b4.zip
Fixed bug #821.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@10134 35acf78f-673a-0410-8e92-d51de3d6d3f4
-rw-r--r--os/hal/ports/STM32/LLD/RTCv2/hal_rtc_lld.c3
-rw-r--r--readme.txt2
2 files changed, 4 insertions, 1 deletions
diff --git a/os/hal/ports/STM32/LLD/RTCv2/hal_rtc_lld.c b/os/hal/ports/STM32/LLD/RTCv2/hal_rtc_lld.c
index a6c776d3a..09844f680 100644
--- a/os/hal/ports/STM32/LLD/RTCv2/hal_rtc_lld.c
+++ b/os/hal/ports/STM32/LLD/RTCv2/hal_rtc_lld.c
@@ -509,6 +509,7 @@ void rtcSTM32SetPeriodicWakeup(RTCDriver *rtcp, const RTCWakeup *wakeupspec) {
osalDbgCheck(wakeupspec->wutr != 0x30000);
rtcp->rtc->CR &= ~RTC_CR_WUTE;
+ rtcp->rtc->CR &= ~RTC_CR_WUTIE;
while (!(rtcp->rtc->ISR & RTC_ISR_WUTWF))
;
rtcp->rtc->WUTR = wakeupspec->wutr & 0xFFFF;
@@ -518,8 +519,8 @@ void rtcSTM32SetPeriodicWakeup(RTCDriver *rtcp, const RTCWakeup *wakeupspec) {
rtcp->rtc->CR |= RTC_CR_WUTE;
}
else {
- rtcp->rtc->CR &= ~RTC_CR_WUTIE;
rtcp->rtc->CR &= ~RTC_CR_WUTE;
+ rtcp->rtc->CR &= ~RTC_CR_WUTIE;
}
/* Leaving a reentrant critical zone.*/
diff --git a/readme.txt b/readme.txt
index 0c303f2f1..ee17396ce 100644
--- a/readme.txt
+++ b/readme.txt
@@ -157,6 +157,8 @@
- RT: Merged RT4.
- NIL: Merged NIL2.
- NIL: Added STM32F7 demo.
+- HAL: Fixed problem in rtcSTM32SetPeriodicWakeup() (bug #821)(backported
+ to 16.1.8).
- HAL: Fixed STM32 RTCv1 synchronization problem (bug #820)(backported
to 16.1.8).
- HAL: Fixed wrong clock source definition for LPTIM on STM32L0xx (bug #819)