From 600403a8666da95c8a9e99497b93825cce63c750 Mon Sep 17 00:00:00 2001 From: Ian Moffett Date: Tue, 21 May 2024 11:40:32 -0400 Subject: kernel: Initial sched rewrite - Introduce dynamic scheduling policy - Introduce MLFQ scheduling - Clean up a lot of code Signed-off-by: Ian Moffett --- sys/arch/amd64/amd64/cpu_mp.c | 5 +---- sys/arch/amd64/conf/GENERIC | 1 + 2 files changed, 2 insertions(+), 4 deletions(-) (limited to 'sys/arch/amd64') diff --git a/sys/arch/amd64/amd64/cpu_mp.c b/sys/arch/amd64/amd64/cpu_mp.c index 7b95196..2afdd43 100644 --- a/sys/arch/amd64/amd64/cpu_mp.c +++ b/sys/arch/amd64/amd64/cpu_mp.c @@ -51,18 +51,15 @@ static bool is_mp_supported = false; static void ap_trampoline(struct limine_smp_info *si) { - struct cpu_info *ci; static struct spinlock lock = {0}; spinlock_acquire(&lock); - ci = (void *)si->extra_argument; pre_init(); processor_init(); spinlock_release(&lock); - - sched_init_processor(ci); + sched_enter(); /* Should not be reached */ __assert(0); diff --git a/sys/arch/amd64/conf/GENERIC b/sys/arch/amd64/conf/GENERIC index 0baff12..b4fb29d 100644 --- a/sys/arch/amd64/conf/GENERIC +++ b/sys/arch/amd64/conf/GENERIC @@ -5,3 +5,4 @@ option PANIC_BEEP yes // Kernel constants setval PANIC_BEEP_HZ 1050 +setval SCHED_NQUEUE 4 -- cgit v1.2.3