summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLouis Burda <quent.burda@gmail.com>2023-02-08 20:16:20 +0100
committerLouis Burda <quent.burda@gmail.com>2023-02-08 20:20:04 +0100
commit3ba1aea797bcf29a772544bf849c3c66481dd52f (patch)
tree1df19886e7395c2447f08fd09a807215a41c63e4
parent3b6a2b6b7466f6dea53243900b7516c3f29027b7 (diff)
downloadcachepc-qemu-master.tar.gz
cachepc-qemu-master.zip
Disable AES-NI instructions in CPUID reportHEADmaster
-rw-r--r--target/i386/sev.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/target/i386/sev.c b/target/i386/sev.c
index c5160aa8ca..ee50efb8f7 100644
--- a/target/i386/sev.c
+++ b/target/i386/sev.c
@@ -1242,6 +1242,9 @@ sev_snp_cpuid_info_fill(SnpCpuidInfo *snp_cpuid_info,
snp_cpuid_entry->ecx = kvm_cpuid_entry->ecx;
snp_cpuid_entry->edx = kvm_cpuid_entry->edx;
+ /* CachePC: disable AES-NI */
+ snp_cpuid_entry->ecx &= ~(1 << 25);
+
/*
* Guest kernels will calculate EBX themselves using the 0xD
* subfunctions corresponding to the individual XSAVE areas, so only