aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--os/hal/platforms/STM32/RTCv2/rtc_lld.h4
-rw-r--r--os/hal/platforms/STM32F4xx/hal_lld.h3
2 files changed, 4 insertions, 3 deletions
diff --git a/os/hal/platforms/STM32/RTCv2/rtc_lld.h b/os/hal/platforms/STM32/RTCv2/rtc_lld.h
index a9346b5ac..3f0139f00 100644
--- a/os/hal/platforms/STM32/RTCv2/rtc_lld.h
+++ b/os/hal/platforms/STM32/RTCv2/rtc_lld.h
@@ -87,6 +87,10 @@
#define RTC_USE_INTERRUPTS FALSE
#endif
+#if STM32_PCLK1 < (STM32_RTCCLK * 7)
+#error "STM32_PCLK1 frequency is too low to handle RTC without ugly workaround"
+#endif
+
/*===========================================================================*/
/* Driver data structures and types. */
/*===========================================================================*/
diff --git a/os/hal/platforms/STM32F4xx/hal_lld.h b/os/hal/platforms/STM32F4xx/hal_lld.h
index a29c33cde..c88ac3a96 100644
--- a/os/hal/platforms/STM32F4xx/hal_lld.h
+++ b/os/hal/platforms/STM32F4xx/hal_lld.h
@@ -1103,9 +1103,6 @@
#if STM32_PCLK1 > STM32_PCLK1_MAX
#error "STM32_PCLK1 exceeding maximum frequency (STM32_PCLK1_MAX)"
#endif
-#if STM32_PCLK1 < (STM32_RTCCLK * 7)
-#error "STM32_PCLK1 frequency is too low to handle RTC without ugly workaround"
-#endif
/**
* @brief APB2 frequency.