|
PatchworkOS
966e257
A non-POSIX operating system.
|
#include <kernel/cpu/cpu.h>#include <kernel/cpu/interrupt.h>#include <kernel/cpu/irq.h>#include <kernel/cpu/syscall.h>#include <kernel/log/log.h>#include <kernel/log/panic.h>#include <kernel/module/symbol.h>#include <kernel/sched/clock.h>#include <kernel/sched/thread.h>#include <kernel/sched/timer.h>#include <kernel/sync/rwlock.h>#include <stdbool.h>#include <stdint.h>#include <sys/math.h>#include <time.h>Go to the source code of this file.
Functions | |
| void | timer_cpu_ctx_init (timer_cpu_ctx_t *ctx) |
| Initialize per-CPU timer context. | |
| void | timer_ack_eoi (interrupt_frame_t *frame, cpu_t *self) |
| Acknowledge a timer interrupt and send EOI. | |
| uint64_t | timer_source_register (const timer_source_t *source) |
| Register a timer source. | |
| void | timer_source_unregister (const timer_source_t *source) |
| Unregister a timer source. | |
| uint64_t | timer_source_amount (void) |
| Get the amount of registered timer sources. | |
| void | timer_set (clock_t uptime, clock_t deadline) |
| Schedule a one-shot timer interrupt on the current CPU. | |
Variables | |
| static const timer_source_t * | sources [TIMER_MAX_SOURCES] = {0} |
| static uint32_t | sourceCount = 0 |
| static const timer_source_t * | bestSource = NULL |
| static rwlock_t | sourcesLock = RWLOCK_CREATE() |
|
static |
|
static |
|
static |