From: Xin Li (Intel) Date: Fri, 22 Aug 2025 07:16:44 +0000 (-0700) Subject: x86/entry/fred: Push __KERNEL_CS directly X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=5be502174bf0f5d0aafaab57fa4512723d6d2973;p=users%2Fhch%2Fmisc.git x86/entry/fred: Push __KERNEL_CS directly Push __KERNEL_CS directly, rather than moving it into RAX and then pushing RAX. No functional changes. Suggested-by: H. Peter Anvin (Intel) Signed-off-by: Xin Li (Intel) Signed-off-by: Borislav Petkov (AMD) Link: https://lore.kernel.org/20250822071644.1405268-1-xin@zytor.com --- diff --git a/arch/x86/entry/entry_64_fred.S b/arch/x86/entry/entry_64_fred.S index 29c5c32c16c3..cb5ff2b1f6e7 100644 --- a/arch/x86/entry/entry_64_fred.S +++ b/arch/x86/entry/entry_64_fred.S @@ -97,8 +97,7 @@ SYM_FUNC_START(asm_fred_entry_from_kvm) push %rdi /* fred_ss handed in by the caller */ push %rbp pushf - mov $__KERNEL_CS, %rax - push %rax + push $__KERNEL_CS /* * Unlike the IDT event delivery, FRED _always_ pushes an error code