From: John Stultz Date: Wed, 14 Jul 2010 00:56:24 +0000 (-0700) Subject: um: Convert to use read_persistent_clock X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=9f31f5774961a735687fee17953ab505b3df3abf;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git um: Convert to use read_persistent_clock This patch converts the um arch to use read_persistent_clock(). This allows it to avoid accessing xtime and wall_to_monotonic directly. Signed-off-by: John Stultz Cc: Jeff Dike LKML-Reference: <1279068988-21864-8-git-send-email-johnstul@us.ibm.com> Signed-off-by: Thomas Gleixner --- diff --git a/arch/um/kernel/time.c b/arch/um/kernel/time.c index c8b9c469fcd7..2b8b262e5c23 100644 --- a/arch/um/kernel/time.c +++ b/arch/um/kernel/time.c @@ -102,16 +102,17 @@ static void __init setup_itimer(void) clockevents_register_device(&itimer_clockevent); } +void read_persistent_clock(struct timespec *ts) +{ + nsecs = os_nsecs(); + set_normalized_timespec(ts, nsecs / NSEC_PER_SEC, + nsecs % NSEC_PER_SEC); +} + void __init time_init(void) { long long nsecs; timer_init(); - - nsecs = os_nsecs(); - set_normalized_timespec(&wall_to_monotonic, -nsecs / NSEC_PER_SEC, - -nsecs % NSEC_PER_SEC); - set_normalized_timespec(&xtime, nsecs / NSEC_PER_SEC, - nsecs % NSEC_PER_SEC); late_time_init = setup_itimer; }