diff options
author | Eduardo Habkost <ehabkost@redhat.com> | 2014-02-19 11:58:12 -0300 |
---|---|---|
committer | Andreas Färber <afaerber@suse.de> | 2014-03-13 19:01:49 +0100 |
commit | ef02ef5f4536dba090b12360a6c862ef0e57e3bc (patch) | |
tree | 154e65257df6cb8deaa2bb9fc18cd792fa7680bf /target-i386 | |
parent | 8fb4f821e93a75431973bf3a11bacd924e43816c (diff) |
target-i386: Enable x2apic by default on KVM
When on KVM mode, enable x2apic by default on all CPU models.
Normally we try to keep the CPU model definitions as close as the real
CPUs as possible, but x2apic can be emulated by KVM without host CPU
support for x2apic, and it improves performance by reducing APIC access
overhead. x2apic emulation is available on KVM since 2009 (Linux
2.6.32-rc1), there's no reason for not enabling x2apic by default when
running KVM.
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Andreas Färber <afaerber@suse.de>
Diffstat (limited to 'target-i386')
-rw-r--r-- | target-i386/cpu.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/target-i386/cpu.c b/target-i386/cpu.c index 5f960acad8..ea2033215f 100644 --- a/target-i386/cpu.c +++ b/target-i386/cpu.c @@ -369,6 +369,7 @@ static uint32_t kvm_default_features[FEATURE_WORDS] = { (1 << KVM_FEATURE_STEAL_TIME) | (1 << KVM_FEATURE_PV_EOI) | (1 << KVM_FEATURE_CLOCKSOURCE_STABLE_BIT), + [FEAT_1_ECX] = CPUID_EXT_X2APIC, }; void x86_cpu_compat_disable_kvm_features(FeatureWord w, uint32_t features) |