From e19e6b33883f515b7075e04a422841415fda70b4 Mon Sep 17 00:00:00 2001 From: Ksawlii Date: Sun, 24 Nov 2024 00:22:51 +0100 Subject: [PATCH] Revert "x86/entry_32: Do not clobber user EFLAGS.ZF" This reverts commit 632fba79b907c415bc979f0b71ef80eebe9f2915. --- arch/x86/entry/entry_32.S | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/arch/x86/entry/entry_32.S b/arch/x86/entry/entry_32.S index 27d558260..97d422f31 100755 --- a/arch/x86/entry/entry_32.S +++ b/arch/x86/entry/entry_32.S @@ -939,8 +939,6 @@ SYM_FUNC_START(entry_SYSENTER_32) /* Now ready to switch the cr3 */ SWITCH_TO_USER_CR3 scratch_reg=%eax - /* Clobbers ZF */ - CLEAR_CPU_BUFFERS /* * Restore all flags except IF. (We restore IF separately because @@ -951,6 +949,7 @@ SYM_FUNC_START(entry_SYSENTER_32) BUG_IF_WRONG_CR3 no_user_check=1 popfl popl %eax + CLEAR_CPU_BUFFERS /* * Return back to the vDSO, which will pop ecx and edx.