1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 04:27:43 +00:00

Generalize the SpinLock and move it to AK.

Add a separate lock to protect the VFS. I think this might be a good idea.
I'm not sure it's a good approach though. I'll fiddle with it as I go along.

It's really fun to figure out all these things on my own.
This commit is contained in:
Andreas Kling 2018-10-23 23:32:53 +02:00
parent e4bfcd2346
commit 018da1be11
11 changed files with 88 additions and 203 deletions

View file

@ -95,23 +95,6 @@ void clock_handle()
current->tss().cs = regs.cs;
current->tss().eflags = regs.eflags;
#if 0
BYTE a = vga_get_attr();
WORD foo = vga_get_cursor();
vga_set_attr(0x50);
vga_set_cursor(0);
kprintf("\n\n");
kprintf("Task %u interrupted at %x \n", current->pid(), regs.eip );
kprintf("EAX=%x EBX=%x ECX=%x EDX=%x \n", regs.eax, regs.ebx, regs.ecx, regs.edx);
kprintf("ESI=%x EDI=%x EBP=%x ESP=%x \n", regs.esi, regs.edi, regs.ebp, regs.esp);
kprintf("FLAGS=%x", regs.eflags);
vga_set_cursor(foo);
vga_set_attr(a);
#endif
// Compute task ESP.
// Add 12 for CS, EIP, EFLAGS (interrupt mechanic)