2 * linux/include/asm-arm/mach/time.h
4 * Copyright (C) 2004 MontaVista Software, Inc.
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 2 as
8 * published by the Free Software Foundation.
10 #ifndef __ASM_ARM_MACH_TIME_H
11 #define __ASM_ARM_MACH_TIME_H
13 #include <linux/sysdev.h>
16 * This is our kernel timer structure.
19 * Initialise the kernels jiffy timer source, claim interrupt
20 * using setup_irq. This is called early on during initialisation
21 * while interrupts are still disabled on the local CPU.
23 * Suspend the kernel jiffy timer source, if necessary. This
24 * is called with interrupts disabled, after all normal devices
25 * have been suspended. If no action is required, set this to
28 * Resume the kernel jiffy timer source, if necessary. This
29 * is called with interrupts disabled before any normal devices
30 * are resumed. If no action is required, set this to NULL.
32 * Return the timer offset in microseconds since the last timer
33 * interrupt. Note: this must take account of any unprocessed
34 * timer interrupt which may be pending.
37 struct sys_device dev
;
39 void (*suspend
)(void);
41 unsigned long (*offset
)(void);
44 extern struct sys_timer
*system_timer
;
45 extern void timer_tick(struct pt_regs
*);
48 * Kernel time keeping support.
50 extern int (*set_rtc
)(void);
51 extern void save_time_delta(struct timespec
*delta
, struct timespec
*rtc
);
52 extern void restore_time_delta(struct timespec
*delta
, struct timespec
*rtc
);