summaryrefslogtreecommitdiff
path: root/arch/x86/mm/mem_encrypt_amd.c
diff options
context:
space:
mode:
authorBartosz Golaszewski <bartosz.golaszewski@linaro.org>2023-12-27 15:41:04 +0100
committerBartosz Golaszewski <bartosz.golaszewski@linaro.org>2023-12-27 15:41:04 +0100
commit4ccdaba5ab560862f89d1d971fbcc2ef424e1867 (patch)
treea7931e13df9cc887017eaa143b4dac66de959d90 /arch/x86/mm/mem_encrypt_amd.c
parent1cdc605c7d70a390ff75a814a26c6f45d75778be (diff)
parent861deac3b092f37b2c5e6871732f3e11486f7082 (diff)
Merge tag 'v6.7-rc7' into gpio/for-next
Linux 6.7-rc7
Diffstat (limited to 'arch/x86/mm/mem_encrypt_amd.c')
-rw-r--r--arch/x86/mm/mem_encrypt_amd.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/arch/x86/mm/mem_encrypt_amd.c b/arch/x86/mm/mem_encrypt_amd.c
index a68f2dda0948..70b91de2e053 100644
--- a/arch/x86/mm/mem_encrypt_amd.c
+++ b/arch/x86/mm/mem_encrypt_amd.c
@@ -32,6 +32,7 @@
#include <asm/msr.h>
#include <asm/cmdline.h>
#include <asm/sev.h>
+#include <asm/ia32.h>
#include "mm_internal.h"
@@ -481,6 +482,16 @@ void __init sme_early_init(void)
*/
if (sev_status & MSR_AMD64_SEV_ES_ENABLED)
x86_cpuinit.parallel_bringup = false;
+
+ /*
+ * The VMM is capable of injecting interrupt 0x80 and triggering the
+ * compatibility syscall path.
+ *
+ * By default, the 32-bit emulation is disabled in order to ensure
+ * the safety of the VM.
+ */
+ if (sev_status & MSR_AMD64_SEV_ENABLED)
+ ia32_disable();
}
void __init mem_encrypt_free_decrypted_mem(void)