aboutsummaryrefslogtreecommitdiffstats
path: root/arch/blackfin/kernel/time-ts.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/blackfin/kernel/time-ts.c')
-rw-r--r--arch/blackfin/kernel/time-ts.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/arch/blackfin/kernel/time-ts.c b/arch/blackfin/kernel/time-ts.c
index cb7a01d4f009..8c9a43daf80f 100644
--- a/arch/blackfin/kernel/time-ts.c
+++ b/arch/blackfin/kernel/time-ts.c
@@ -353,9 +353,15 @@ void bfin_coretmr_clockevent_init(void)
353#endif /* CONFIG_TICKSOURCE_CORETMR */ 353#endif /* CONFIG_TICKSOURCE_CORETMR */
354 354
355 355
356void __init time_init(void) 356void read_persistent_clock(struct timespec *ts)
357{ 357{
358 time_t secs_since_1970 = (365 * 37 + 9) * 24 * 60 * 60; /* 1 Jan 2007 */ 358 time_t secs_since_1970 = (365 * 37 + 9) * 24 * 60 * 60; /* 1 Jan 2007 */
359 ts->tv_sec = secs_since_1970;
360 ts->tv_nsec = 0;
361}
362
363void __init time_init(void)
364{
359 365
360#ifdef CONFIG_RTC_DRV_BFIN 366#ifdef CONFIG_RTC_DRV_BFIN
361 /* [#2663] hack to filter junk RTC values that would cause 367 /* [#2663] hack to filter junk RTC values that would cause
@@ -368,11 +374,6 @@ void __init time_init(void)
368 } 374 }
369#endif 375#endif
370 376
371 /* Initialize xtime. From now on, xtime is updated with timer interrupts */
372 xtime.tv_sec = secs_since_1970;
373 xtime.tv_nsec = 0;
374 set_normalized_timespec(&wall_to_monotonic, -xtime.tv_sec, -xtime.tv_nsec);
375
376 bfin_cs_cycles_init(); 377 bfin_cs_cycles_init();
377 bfin_cs_gptimer0_init(); 378 bfin_cs_gptimer0_init();
378 379