timer.h 634 B

12345678910111213141516171819202122232425262728293031323334
  1. #ifndef __ASM_SH_TIMER_H
  2. #define __ASM_SH_TIMER_H
  3. #include <linux/sysdev.h>
  4. #include <linux/clocksource.h>
  5. #include <cpu/timer.h>
  6. struct sys_timer_ops {
  7. int (*init)(void);
  8. int (*start)(void);
  9. int (*stop)(void);
  10. };
  11. struct sys_timer {
  12. const char *name;
  13. struct sys_device dev;
  14. struct sys_timer_ops *ops;
  15. };
  16. #define TICK_SIZE (tick_nsec / 1000)
  17. extern struct sys_timer tmu_timer;
  18. extern struct sys_timer *sys_timer;
  19. /* arch/sh/kernel/timers/timer.c */
  20. struct sys_timer *get_sys_timer(void);
  21. /* arch/sh/kernel/time.c */
  22. void handle_timer_tick(void);
  23. extern struct clocksource clocksource_sh;
  24. #endif /* __ASM_SH_TIMER_H */