Commit 0272282f7cffb469cd2676dcb6e58bc942fcf8a8

Authored by John Stultz
Committed by Paul Mundt
1 parent 62c8cbbfc2

sh: Convert sh to use read/update_persistent_clock

This patch converts the sh architecture to use the generic
read_persistent_clock and update_persistent_clock interfaces, reducing
the amount of arch specific code we have to maintain, and allowing for
further cleanups in the future.

Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: John Stultz <johnstul@us.ibm.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>

Showing 1 changed file with 1 additions and 5 deletions Side-by-side Diff

arch/sh/kernel/time.c
... ... @@ -39,12 +39,12 @@
39 39 void (*rtc_sh_get_time)(struct timespec *) = null_rtc_get_time;
40 40 int (*rtc_sh_set_time)(const time_t) = null_rtc_set_time;
41 41  
42   -#ifdef CONFIG_GENERIC_CMOS_UPDATE
43 42 void read_persistent_clock(struct timespec *ts)
44 43 {
45 44 rtc_sh_get_time(ts);
46 45 }
47 46  
  47 +#ifdef CONFIG_GENERIC_CMOS_UPDATE
48 48 int update_persistent_clock(struct timespec now)
49 49 {
50 50 return rtc_sh_set_time(now.tv_sec);
... ... @@ -112,10 +112,6 @@
112 112  
113 113 hwblk_init();
114 114 clk_init();
115   -
116   - rtc_sh_get_time(&xtime);
117   - set_normalized_timespec(&wall_to_monotonic,
118   - -xtime.tv_sec, -xtime.tv_nsec);
119 115  
120 116 late_time_init = sh_late_time_init;
121 117 }