Skip to content

Commit 5be5021

Browse files
xinli-intelbp3tk0v
authored andcommitted
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) <hpa@zytor.com> Signed-off-by: Xin Li (Intel) <xin@zytor.com> Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de> Link: https://lore.kernel.org/20250822071644.1405268-1-xin@zytor.com
1 parent ae7c099 commit 5be5021

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

arch/x86/entry/entry_64_fred.S

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,7 @@ SYM_FUNC_START(asm_fred_entry_from_kvm)
9797
push %rdi /* fred_ss handed in by the caller */
9898
push %rbp
9999
pushf
100-
mov $__KERNEL_CS, %rax
101-
push %rax
100+
push $__KERNEL_CS
102101

103102
/*
104103
* Unlike the IDT event delivery, FRED _always_ pushes an error code

0 commit comments

Comments
 (0)