2009-11-06 10:04:15 +01:00
|
|
|
#ifndef __CLOCK_H__
|
|
|
|
#define __CLOCK_H__
|
|
|
|
|
|
|
|
#include "kernel.h"
|
2010-04-02 00:22:33 +02:00
|
|
|
#include "arch_clock.h"
|
2009-11-06 10:04:15 +01:00
|
|
|
|
|
|
|
_PROTOTYPE(int boot_cpu_init_timer, (unsigned freq));
|
2010-09-15 16:10:09 +02:00
|
|
|
_PROTOTYPE(int app_cpu_init_timer, (unsigned freq));
|
2009-11-06 10:04:15 +01:00
|
|
|
|
2010-09-15 16:10:09 +02:00
|
|
|
_PROTOTYPE(int timer_int_handler, (void));
|
2009-11-06 10:04:15 +01:00
|
|
|
|
2010-09-15 16:11:06 +02:00
|
|
|
_PROTOTYPE(int init_local_timer, (unsigned freq));
|
2010-09-15 16:10:57 +02:00
|
|
|
/* sto p the local timer ticking */
|
2010-09-15 16:11:06 +02:00
|
|
|
_PROTOTYPE(void stop_local_timer, (void));
|
2010-09-15 16:10:57 +02:00
|
|
|
/* let the time tick again with the original settings after it was stopped */
|
2010-09-15 16:11:06 +02:00
|
|
|
_PROTOTYPE(void restart_local_timer, (void));
|
|
|
|
_PROTOTYPE(int register_local_timer_handler, (irq_handler_t handler));
|
2009-11-06 10:04:15 +01:00
|
|
|
|
2010-05-25 10:06:14 +02:00
|
|
|
_PROTOTYPE( u64_t ms_2_cpu_time, (unsigned ms));
|
2010-09-19 17:52:12 +02:00
|
|
|
_PROTOTYPE( unsigned cpu_time_2_ms, (u64_t cpu_time));
|
2010-05-25 10:06:14 +02:00
|
|
|
|
2009-11-06 10:04:15 +01:00
|
|
|
#endif /* __CLOCK_H__ */
|