by entering a system call, we need also to push the segment descriptor on the stack
This commit is contained in:
parent
04a0dfb114
commit
624afd187c
1 changed files with 8 additions and 12 deletions
|
@ -145,7 +145,6 @@ global isr29
|
|||
global isr30
|
||||
global isr31
|
||||
global isrsyscall
|
||||
global jump_to_child
|
||||
|
||||
; 0: Divide By Zero Exception
|
||||
isr0:
|
||||
|
@ -433,6 +432,10 @@ extern syscall_handler
|
|||
|
||||
; used to realize system calls
|
||||
isrsyscall:
|
||||
push ds
|
||||
push fs
|
||||
push gs
|
||||
push es
|
||||
push ebp
|
||||
push edi
|
||||
push esi
|
||||
|
@ -449,17 +452,10 @@ isrsyscall:
|
|||
pop esi
|
||||
pop edi
|
||||
pop ebp
|
||||
iret
|
||||
|
||||
jump_to_child:
|
||||
add esp, 4
|
||||
mov eax, 0 ; child got always zero as return value
|
||||
pop ebx
|
||||
pop ecx
|
||||
pop edx
|
||||
pop esi
|
||||
pop edi
|
||||
pop ebp
|
||||
pop es
|
||||
pop gs
|
||||
pop fs
|
||||
pop ds
|
||||
iret
|
||||
|
||||
global irq0
|
||||
|
|
Loading…
Add table
Reference in a new issue