summaryrefslogtreecommitdiff
path: root/arch/x86/entry
diff options
context:
space:
mode:
authorBrian Gerst <brgerst@gmail.com>2023-07-21 19:10:16 +0300
committerIngo Molnar <mingo@kernel.org>2023-10-05 11:06:43 +0300
commitbab9fa6dc5e4483749838877deebe038de3ce97e (patch)
treebb6b5a27f00aa9d0b98710227f661f260a7a938d /arch/x86/entry
parent0d3109ad2e6125add5b3c88e8de3fb7bfd4e8c49 (diff)
downloadlinux-bab9fa6dc5e4483749838877deebe038de3ce97e.tar.xz
x86/entry/32: Remove SEP test for SYSEXIT
SEP must be already be present in order for do_fast_syscall_32() to be called on native 32-bit, so checking it again is unnecessary. Signed-off-by: Brian Gerst <brgerst@gmail.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> Link: https://lore.kernel.org/r/20230721161018.50214-6-brgerst@gmail.com
Diffstat (limited to 'arch/x86/entry')
-rw-r--r--arch/x86/entry/common.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/arch/x86/entry/common.c b/arch/x86/entry/common.c
index f1f3bf150b57..0551bcb197fb 100644
--- a/arch/x86/entry/common.c
+++ b/arch/x86/entry/common.c
@@ -238,8 +238,7 @@ __visible noinstr bool do_fast_syscall_32(struct pt_regs *regs)
* We don't allow syscalls at all from VM86 mode, but we still
* need to check VM, because we might be returning from sys_vm86.
*/
- return static_cpu_has(X86_FEATURE_SEP) &&
- regs->cs == __USER_CS && regs->ss == __USER_DS &&
+ return regs->cs == __USER_CS && regs->ss == __USER_DS &&
regs->ip == landing_pad &&
(regs->flags & (X86_EFLAGS_RF | X86_EFLAGS_TF | X86_EFLAGS_VM)) == 0;
#endif