From 1eeb66af44ab335888410d716d604e569f20866e Mon Sep 17 00:00:00 2001 From: dzwdz Date: Fri, 15 Jul 2022 11:16:11 +0200 Subject: i686: stop using pushal/popal in sysenter/sysexit --- src/kernel/arch/i386/sysenter.s | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) (limited to 'src/kernel/arch/i386') diff --git a/src/kernel/arch/i386/sysenter.s b/src/kernel/arch/i386/sysenter.s index edfabf0..d04f839 100644 --- a/src/kernel/arch/i386/sysenter.s +++ b/src/kernel/arch/i386/sysenter.s @@ -45,7 +45,14 @@ _sysexit_real: // restore the registers mov $_sysexit_regs, %esp - popal + pop %edi + pop %esi + pop %ebp + add $4, %esp + pop %ebx + pop %edx + pop %ecx + pop %eax // enable paging mov %eax, stored_eax @@ -69,7 +76,14 @@ sysenter_stage1: // save the registers mov $(_sysexit_regs + 32), %esp - pushal + push %eax + push %ecx + push %edx + push %ebx + push $0x0 // pushal pushes %esp here, but that's worthless + push %ebp + push %esi + push %edi mov $_bss_end, %esp jmp sysenter_stage2 -- cgit v1.2.3