10 #include <linux/errno.h>
11 #include <linux/sched.h>
12 #include <linux/kernel.h>
14 #include <linux/string.h>
18 #include <linux/timex.h>
20 #include <asm/segment.h>
26 #if CONFIG_H8300_TIMER16_CH == 0
27 #define _16BASE 0xffff78
29 #elif CONFIG_H8300_TIMER16_CH == 1
30 #define _16BASE 0xffff80
32 #elif CONFIG_H8300_TIMER16_CH == 2
33 #define _16BASE 0xffff88
36 #error Unknown timer channel.
45 #define H8300_TIMER_FREQ CONFIG_CPU_CLOCK*10000
50 ctrl_bclr(CONFIG_H8300_TIMER16_CH, TISRA);
60 static const int __initconst divide_rate[] = {1, 2, 4, 8};
75 ctrl_bset(4 + CONFIG_H8300_TIMER16_CH, TISRA);
76 ctrl_bset(CONFIG_H8300_TIMER16_CH,
TSTR);