From 624afd187cc40487894fba7e291dbc5e01ad137f Mon Sep 17 00:00:00 2001 From: Stefan Lankes Date: Mon, 18 Apr 2011 15:05:27 +0200 Subject: [PATCH] by entering a system call, we need also to push the segment descriptor on the stack --- arch/x86/kernel/entry.asm | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/arch/x86/kernel/entry.asm b/arch/x86/kernel/entry.asm index f24b33dd..1a325dba 100644 --- a/arch/x86/kernel/entry.asm +++ b/arch/x86/kernel/entry.asm @@ -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