aboutsummaryrefslogtreecommitdiff
path: root/target
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2020-02-11 18:47:48 +0100
committerPaolo Bonzini <pbonzini@redhat.com>2020-02-12 16:29:51 +0100
commitbe02cda3afde60d219786e23c3f8edb53aec8e17 (patch)
treebbef66c43b4ddce6dce2fa6dc1274a65775c7791 /target
parent6702514814c7e7b4cbf179624539b5f38c72740b (diff)
target/i386: enable monitor and ucode revision with -cpu max
These two features were incorrectly tied to host_cpuid_required rather than cpu->max_features. As a result, -cpu max was not enabling either MONITOR features or ucode revision. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'target')
-rw-r--r--target/i386/cpu.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/target/i386/cpu.c b/target/i386/cpu.c
index 32efa46852..92fafa2659 100644
--- a/target/i386/cpu.c
+++ b/target/i386/cpu.c
@@ -6414,7 +6414,9 @@ static void x86_cpu_realizefn(DeviceState *dev, Error **errp)
error_setg(&local_err, "CPU model '%s' requires KVM", name);
goto out;
}
+ }
+ if (cpu->max_features && accel_uses_host_cpuid()) {
if (enable_cpu_pm) {
host_cpuid(5, 0, &cpu->mwait.eax, &cpu->mwait.ebx,
&cpu->mwait.ecx, &cpu->mwait.edx);