diff options
author | Stephen Warren <swarren@nvidia.com> | 2012-11-08 13:51:58 -0500 |
---|---|---|
committer | Stephen Warren <swarren@nvidia.com> | 2012-12-24 11:36:35 -0500 |
commit | 23c197b77f9553c30f9c8a5ab41279a35f135f37 (patch) | |
tree | 7da1f4b032ff24482afb1f289ab9c633de684d7a /arch/arm/mach-h720x/cpu-h7201.c | |
parent | c8d5ba1891eda2aa63800f052cb5af128283d130 (diff) |
ARM: set arch_gettimeoffset directly
remove ARM's struct sys_timer .offset function pointer, and instead
directly set the arch_gettimeoffset function pointer when the timer
driver is initialized. This requires multiplying all function results
by 1000, since the removed arm_gettimeoffset() did this. Also,
s/unsigned long/u32/ just to make the function prototypes exactly
match that of arch_gettimeoffset.
Cc: Russell King <linux@arm.linux.org.uk>
Cc: Andrew Victor <linux@maxim.org.za>
Cc: Nicolas Ferre <nicolas.ferre@atmel.com>
Cc: Jean-Christophe Plagniol-Villard <plagnioj@jcrosoft.com>
Cc: Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Ryan Mallon <rmallon@gmail.com>
Cc: Ben Dooks <ben-linux@fluff.org>
Cc: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Stephen Warren <swarren@nvidia.com>
Diffstat (limited to 'arch/arm/mach-h720x/cpu-h7201.c')
-rw-r--r-- | arch/arm/mach-h720x/cpu-h7201.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/arm/mach-h720x/cpu-h7201.c b/arch/arm/mach-h720x/cpu-h7201.c index 24df2a349a98..ba349cffcd3a 100644 --- a/arch/arm/mach-h720x/cpu-h7201.c +++ b/arch/arm/mach-h720x/cpu-h7201.c | |||
@@ -46,6 +46,8 @@ static struct irqaction h7201_timer_irq = { | |||
46 | */ | 46 | */ |
47 | void __init h7201_init_time(void) | 47 | void __init h7201_init_time(void) |
48 | { | 48 | { |
49 | arch_gettimeoffset = h720x_gettimeoffset; | ||
50 | |||
49 | CPU_REG (TIMER_VIRT, TM0_PERIOD) = LATCH; | 51 | CPU_REG (TIMER_VIRT, TM0_PERIOD) = LATCH; |
50 | CPU_REG (TIMER_VIRT, TM0_CTRL) = TM_RESET; | 52 | CPU_REG (TIMER_VIRT, TM0_CTRL) = TM_RESET; |
51 | CPU_REG (TIMER_VIRT, TM0_CTRL) = TM_REPEAT | TM_START; | 53 | CPU_REG (TIMER_VIRT, TM0_CTRL) = TM_REPEAT | TM_START; |
@@ -56,5 +58,4 @@ void __init h7201_init_time(void) | |||
56 | 58 | ||
57 | struct sys_timer h7201_timer = { | 59 | struct sys_timer h7201_timer = { |
58 | .init = h7201_init_time, | 60 | .init = h7201_init_time, |
59 | .offset = h720x_gettimeoffset, | ||
60 | }; | 61 | }; |