Enable the PIC and add a timer.

This causes a GP fault after the timer runs for some time.
This commit is contained in:
Drew Galbraith 2023-05-29 21:52:01 -07:00
parent 80d2bf1aaa
commit 629dca278b
6 changed files with 76 additions and 0 deletions

View file

@ -3,6 +3,7 @@
#include "common/gdt.h"
#include "debug/debug.h"
#include "interrupt/interrupt.h"
#include "interrupt/timer.h"
#include "loader/init_loader.h"
#include "memory/kernel_heap.h"
#include "memory/paging_util.h"
@ -21,6 +22,7 @@ extern "C" void zion() {
InitSyscall();
SetFrequency(/* hertz= */ 2000);
sched::InitScheduler();
sched::EnableScheduler();