diff options
author | Eduardo Habkost <ehabkost@redhat.com> | 2008-11-17 19:03:16 -0200 |
---|---|---|
committer | Avi Kivity <avi@redhat.com> | 2008-12-31 16:52:28 +0200 |
commit | 6210e37b122583643da335c0389f74098713e5ca (patch) | |
tree | 779f5a7b90ffec49d2eda03c5f30cf6d79395766 /arch/x86/kvm | |
parent | eca70fc5671b226966dfb7ee9953d59199288566 (diff) |
KVM: VMX: move cpu_has_kvm_support() to an inline on asm/virtext.h
It will be used by core code on kdump and reboot, to disable
vmx if needed.
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'arch/x86/kvm')
-rw-r--r-- | arch/x86/kvm/vmx.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c index ec71f6464cf..defaeeb3f75 100644 --- a/arch/x86/kvm/vmx.c +++ b/arch/x86/kvm/vmx.c @@ -31,6 +31,7 @@ #include <asm/io.h> #include <asm/desc.h> #include <asm/vmx.h> +#include <asm/virtext.h> #define __ex(x) __kvm_handle_fault_on_reboot(x) @@ -1044,8 +1045,7 @@ static int vmx_get_irq(struct kvm_vcpu *vcpu) static __init int cpu_has_kvm_support(void) { - unsigned long ecx = cpuid_ecx(1); - return test_bit(5, &ecx); /* CPUID.1:ECX.VMX[bit 5] -> VT */ + return cpu_has_vmx(); } static __init int vmx_disabled_by_bios(void) |