mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 06:47:35 +00:00
Turn the syscall interrupt into a trap (by switching the gate type.)
This leaves interrupts enabled while we're in the kernel, which is precisely what we want. This uncovered a horrendous problem with kernel tasks silently overflowing their stacks. For now I've simply increased the stack size but I need a more MMU-y solution for this eventually.
This commit is contained in:
parent
2d1d01661b
commit
46ff281695
6 changed files with 116 additions and 25 deletions
|
@ -16,12 +16,12 @@ panel_main()
|
|||
|
||||
for( ;; )
|
||||
{
|
||||
c = vga_get_cursor();
|
||||
a = vga_get_attr();
|
||||
|
||||
/* HACK: Avoid getting interrupted while painting since
|
||||
* that could lead to fugly artifacts ;P */
|
||||
disableInterrupts();
|
||||
cli();
|
||||
|
||||
c = vga_get_cursor();
|
||||
a = vga_get_attr();
|
||||
|
||||
vga_set_attr( 0x17 );
|
||||
vga_set_cursor( 80 * 24 );
|
||||
|
@ -39,7 +39,7 @@ panel_main()
|
|||
vga_set_cursor( c );
|
||||
|
||||
/* HACK cont.d */
|
||||
enableInterrupts();
|
||||
sti();
|
||||
|
||||
sleep( 1 * TICKS_PER_SECOND );
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue