[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v14 1/6] i386: Set TOPOEXT unconditionally for comap
From: |
Babu Moger |
Subject: |
[Qemu-devel] [PATCH v14 1/6] i386: Set TOPOEXT unconditionally for comapatibility |
Date: |
Wed, 13 Jun 2018 21:18:22 -0400 |
Enabling TOPOEXT feature might cause compatibility issues if
older kernels does not set this feature. Lets set this feature
unconditionally.
Signed-off-by: Babu Moger <address@hidden>
---
target/i386/kvm.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/target/i386/kvm.c b/target/i386/kvm.c
index 445e0e0..6f2cca7 100644
--- a/target/i386/kvm.c
+++ b/target/i386/kvm.c
@@ -372,6 +372,12 @@ uint32_t kvm_arch_get_supported_cpuid(KVMState *s,
uint32_t function,
if (host_tsx_blacklisted()) {
ret &= ~(CPUID_7_0_EBX_RTM | CPUID_7_0_EBX_HLE);
}
+ } else if (function == 0x80000001 && reg == R_ECX) {
+ /* Enabling topoext feature might cause compatibility issues if
+ * older kernel does not set this feature. Lets set this feature
+ * unconditionally.
+ */
+ ret |= CPUID_EXT3_TOPOEXT;
} else if (function == 0x80000001 && reg == R_EDX) {
/* On Intel, kvm returns cpuid according to the Intel spec,
* so add missing bits according to the AMD spec:
--
1.8.3.1
- [Qemu-devel] [PATCH v14 2/6] i386: Enable TOPOEXT feature on AMD EPYC CPU, (continued)
- [Qemu-devel] [PATCH v14 2/6] i386: Enable TOPOEXT feature on AMD EPYC CPU, Babu Moger, 2018/06/13
- [Qemu-devel] [PATCH v14 4/6] cpus: Add new function topology_supports_topoext, Babu Moger, 2018/06/13
- [Qemu-devel] [PATCH v14 5/6] i386: Disable TOPOEXT feature if it cannot be supported, Babu Moger, 2018/06/13
- [Qemu-devel] [PATCH v14 3/6] i386: Disable TOPOEXT feature on pc-2.12, Babu Moger, 2018/06/13
- [Qemu-devel] [PATCH v14 1/6] i386: Set TOPOEXT unconditionally for comapatibility,
Babu Moger <=
- [Qemu-devel] [PATCH v14 6/6] i386: Remove generic SMT thread check, Babu Moger, 2018/06/13