diff options
Diffstat (limited to 'arch/arm/mach-rpc/time.c')
-rw-r--r-- | arch/arm/mach-rpc/time.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/arm/mach-rpc/time.c b/arch/arm/mach-rpc/time.c index 581fca934bb3..6ddccb0210ac 100644 --- a/arch/arm/mach-rpc/time.c +++ b/arch/arm/mach-rpc/time.c | |||
@@ -24,7 +24,7 @@ | |||
24 | 24 | ||
25 | #include <asm/mach/time.h> | 25 | #include <asm/mach/time.h> |
26 | 26 | ||
27 | unsigned long ioc_timer_gettimeoffset(void) | 27 | static u32 ioc_timer_gettimeoffset(void) |
28 | { | 28 | { |
29 | unsigned int count1, count2, status; | 29 | unsigned int count1, count2, status; |
30 | long offset; | 30 | long offset; |
@@ -56,7 +56,7 @@ unsigned long ioc_timer_gettimeoffset(void) | |||
56 | } | 56 | } |
57 | 57 | ||
58 | offset = (LATCH - offset) * (tick_nsec / 1000); | 58 | offset = (LATCH - offset) * (tick_nsec / 1000); |
59 | return (offset + LATCH/2) / LATCH; | 59 | return ((offset + LATCH/2) / LATCH) * 1000; |
60 | } | 60 | } |
61 | 61 | ||
62 | void __init ioctime_init(void) | 62 | void __init ioctime_init(void) |
@@ -84,12 +84,12 @@ static struct irqaction ioc_timer_irq = { | |||
84 | */ | 84 | */ |
85 | static void __init ioc_timer_init(void) | 85 | static void __init ioc_timer_init(void) |
86 | { | 86 | { |
87 | arch_gettimeoffset = ioc_timer_gettimeoffset; | ||
87 | ioctime_init(); | 88 | ioctime_init(); |
88 | setup_irq(IRQ_TIMER0, &ioc_timer_irq); | 89 | setup_irq(IRQ_TIMER0, &ioc_timer_irq); |
89 | } | 90 | } |
90 | 91 | ||
91 | struct sys_timer ioc_timer = { | 92 | struct sys_timer ioc_timer = { |
92 | .init = ioc_timer_init, | 93 | .init = ioc_timer_init, |
93 | .offset = ioc_timer_gettimeoffset, | ||
94 | }; | 94 | }; |
95 | 95 | ||