drivers/timers/arch_rtc.c: up_rtc_set_lowerhalf call clock_synchronize() for external RTC.

This commit is contained in:
Xiang Xiao 2018-11-09 16:34:07 -06:00 committed by Gregory Nutt
parent a583488829
commit f64741faca

View File

@ -67,8 +67,12 @@ volatile bool g_rtc_enabled = false;
void up_rtc_set_lowerhalf(FAR struct rtc_lowerhalf_s *lower)
{
g_rtc_lower = lower;
g_rtc_lower = lower;
g_rtc_enabled = true;
#ifdef CONFIG_RTC_EXTERNAL
clock_synchronize();
#endif
}
/************************************************************************************