Thread (158 messages) 158 messages, 14 authors, 2024-01-09

Re: [PATCH v10 05/50] x86/speculation: Do not enable Automatic IBRS if SEV SNP is enabled

From: Borislav Petkov <bp@alien8.de>
Date: 2023-10-25 17:34:27
Also in: kvm, linux-crypto, linux-mm, lkml

On Mon, Oct 16, 2023 at 08:27:34AM -0500, Michael Roth wrote:
From: Kim Phillips <redacted>

Without SEV-SNP, Automatic IBRS protects only the kernel. But when
SEV-SNP is enabled, the Automatic IBRS protection umbrella widens to all
host-side code, including userspace. This protection comes at a cost:
reduced userspace indirect branch performance.

To avoid this performance loss, don't use Automatic IBRS on SEV-SNP
hosts. Fall back to retpolines instead.

Signed-off-by: Kim Phillips <redacted>
[mdr: squash in changes from review discussion]
Signed-off-by: Michael Roth <redacted>
---
 arch/x86/kernel/cpu/common.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
Acked-by: Borislav Petkov (AMD) <bp@alien8.de>

-- 
Regards/Gruss,
    Boris.

https://people.kernel.org/tglx/notes-about-netiquette
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help