x86/srso: Add IBPB on VMEXIT
authorBorislav Petkov (AMD) <bp@alien8.de>
Fri, 7 Jul 2023 11:53:41 +0000 (13:53 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 8 Aug 2023 18:03:50 +0000 (20:03 +0200)
commitc9ae63d773ca182c4ef63fbdd22cdf090d9c1cd7
tree1c2aecf6141d7e776f99551cd3228623fa53d52e
parent79c8091888ef61aac79ef72122d1e6cd0b620669
x86/srso: Add IBPB on VMEXIT

Upstream commit: d893832d0e1ef41c72cdae444268c1d64a2be8ad

Add the option to flush IBPB only on VMEXIT in order to protect from
malicious guests but one otherwise trusts the software that runs on the
hypervisor.

Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/x86/include/asm/cpufeatures.h
arch/x86/kernel/cpu/bugs.c
arch/x86/kvm/svm/svm.c
arch/x86/kvm/svm/vmenter.S