diff options
Diffstat (limited to 'src/kernel/timer/timer.c')
-rw-r--r-- | src/kernel/timer/timer.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/kernel/timer/timer.c b/src/kernel/timer/timer.c index 45b254e..f332429 100644 --- a/src/kernel/timer/timer.c +++ b/src/kernel/timer/timer.c @@ -1,7 +1,7 @@ #include "../interrupts/interrupts.h" #include "../io/io.h" -volatile unsigned int timer_ticks = 0; +static unsigned int timer_ticks = 0; void timer_phase(int hz) { int divisor = 1193180 / hz; @@ -25,6 +25,10 @@ void timer_wait(int ticks) { } } +unsigned int get_time() { + return timer_ticks; +} + // Install timer handler into IRQ0 void timer_install() { timer_phase(100); |