diff --git a/src/drivers/clock.c b/src/drivers/clock.c index 78adfce..3ba1213 100644 --- a/src/drivers/clock.c +++ b/src/drivers/clock.c @@ -38,11 +38,10 @@ void clock_init(struct registers *regs) static void clock_handler(struct registers *regs) { - (void)regs; - if (scheduler_counter % 10 == 0) - scheduler((uint32_t *)regs); scheduler_counter++; sleep_counter--; + if (scheduler_counter % 100 == 0) + scheduler((uint32_t *)regs); } void sleep(uint64_t delay) diff --git a/src/kernel.c b/src/kernel.c index 3bd9ea3..a7e7db5 100644 --- a/src/kernel.c +++ b/src/kernel.c @@ -31,6 +31,14 @@ #error "This tutorial needs to be compiled with a ix86-elf compiler" #endif +static void uwu(void) +{ + while (1) { + // sleep(1000); + kprintf("uwu\n"); + } +} + static void bozo(int int_code) { (void)int_code; @@ -47,6 +55,7 @@ void kernel_main(multiboot_info_t *mbd, uint32_t magic) terminal_initialize(); create_process(1); create_thread(current_pcb, shell_init); + create_thread(current_pcb, uwu); toris(); while (true) ;