tasking: make idle task halt

This commit is contained in:
2025-11-20 15:53:57 +03:00
parent 7dc522eb3d
commit c17c23ddd5
2 changed files with 3 additions and 17 deletions
+1 -15
View File
@@ -143,21 +143,7 @@ void kmain(unsigned int magic, unsigned int info)
while(1) while(1)
{ {
if(timer_ticks % 1000 == 0) asm("sti; hlt");
{
//printf("a second should have passed!\n");
} }
/* if(inportb(0x64) & 0x1)
{
unsigned char key = inportb(0x60);
if(key == 2)
terminal_writestring("1\n");
else if(key == 4)
terminal_writestring("3\n");
else
terminal_writestring("dunno what is it\n");
}
*/ }
} }
+1 -1
View File
@@ -196,7 +196,7 @@ void schedule() {
void idle() void idle()
{ {
while (1) {} while (1) { asm volatile("sti; hlt");}
} }
void task1() void task1()