diff options
author | Stephen Warren <swarren@nvidia.com> | 2012-11-08 11:34:55 -0700 |
---|---|---|
committer | Stephen Warren <swarren@nvidia.com> | 2012-12-24 09:36:34 -0700 |
commit | c8d5ba1891eda2aa63800f052cb5af128283d130 (patch) | |
tree | 59a18c2262607b4067739fe4dfed3c6fa8e40f14 /arch/m68k/atari | |
parent | 7b1f62076bba10786d2118006ae68ac120cd6c56 (diff) | |
download | op-kernel-dev-c8d5ba1891eda2aa63800f052cb5af128283d130.zip op-kernel-dev-c8d5ba1891eda2aa63800f052cb5af128283d130.tar.gz |
m68k: set arch_gettimeoffset directly
remove m68k's mach_gettimeoffset function pointer, and instead directly
set the arch_gettimeoffset function pointer. This requires multiplying
all function results by 1000, since the removed m68k_gettimeoffset() did
this. Also, s/unsigned long/u32/ just to make the function prototypes
exactly match that of arch_gettimeoffset.
Cc: Joshua Thompson <funaho@jurai.org>
Cc: Sam Creasey <sammy@sammy.net>
Acked-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: Phil Blundell <philb@gnu.org>
Signed-off-by: Stephen Warren <swarren@nvidia.com>
Diffstat (limited to 'arch/m68k/atari')
-rw-r--r-- | arch/m68k/atari/config.c | 4 | ||||
-rw-r--r-- | arch/m68k/atari/time.c | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/arch/m68k/atari/config.c b/arch/m68k/atari/config.c index d8eb327..037c11c 100644 --- a/arch/m68k/atari/config.c +++ b/arch/m68k/atari/config.c @@ -74,7 +74,7 @@ static void atari_heartbeat(int on); /* atari specific timer functions (in time.c) */ extern void atari_sched_init(irq_handler_t); -extern unsigned long atari_gettimeoffset (void); +extern u32 atari_gettimeoffset(void); extern int atari_mste_hwclk (int, struct rtc_time *); extern int atari_tt_hwclk (int, struct rtc_time *); extern int atari_mste_set_clock_mmss (unsigned long); @@ -204,7 +204,7 @@ void __init config_atari(void) mach_init_IRQ = atari_init_IRQ; mach_get_model = atari_get_model; mach_get_hardware_list = atari_get_hardware_list; - mach_gettimeoffset = atari_gettimeoffset; + arch_gettimeoffset = atari_gettimeoffset; mach_reset = atari_reset; mach_max_dma_address = 0xffffff; #if defined(CONFIG_INPUT_M68K_BEEP) || defined(CONFIG_INPUT_M68K_BEEP_MODULE) diff --git a/arch/m68k/atari/time.c b/arch/m68k/atari/time.c index c0cc68a..da8f981 100644 --- a/arch/m68k/atari/time.c +++ b/arch/m68k/atari/time.c @@ -42,9 +42,9 @@ atari_sched_init(irq_handler_t timer_routine) #define TICK_SIZE 10000 /* This is always executed with interrupts disabled. */ -unsigned long atari_gettimeoffset (void) +u32 atari_gettimeoffset(void) { - unsigned long ticks, offset = 0; + u32 ticks, offset = 0; /* read MFP timer C current value */ ticks = st_mfp.tim_dt_c; @@ -57,7 +57,7 @@ unsigned long atari_gettimeoffset (void) ticks = INT_TICKS - ticks; ticks = ticks * 10000L / INT_TICKS; - return ticks + offset; + return (ticks + offset) * 1000; } |