2 * linux/include/asm-arm/arch-tbox/time.h
4 * Copyright (c) 1997, 1999 Phil Blundell.
5 * Copyright (c) 2000 FutureTV Labs Ltd
7 * Tbox has no real-time clock -- we get millisecond ticks to update
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation; either version
15 * 2 of the License, or (at your option) any later version.
19 #include <asm/hardware.h>
23 static void timer_interrupt (int irq, void *dev_id, struct pt_regs *regs)
26 __raw_writel(1, FPGA1CONT + 0xc);
27 __raw_writel(0, FPGA1CONT + 0xc);
32 static inline void setup_timer (void)
35 * Default the date to 1 Jan 1970 0:0:0
36 * You will have to run a time daemon to set the
37 * clock correctly at bootup
39 xtime.tv_sec = mktime(1970, 1, 1, 0, 0, 0);
41 timer_irq.handler = timer_interrupt;
42 setup_arm_irq(IRQ_TIMER, &timer_irq);