diff options
Diffstat (limited to 'arch/x86/include/asm/kvm_host.h')
-rw-r--r-- | arch/x86/include/asm/kvm_host.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/arch/x86/include/asm/kvm_host.h b/arch/x86/include/asm/kvm_host.h index e0fbe7e70dc1..69e62862b622 100644 --- a/arch/x86/include/asm/kvm_host.h +++ b/arch/x86/include/asm/kvm_host.h | |||
@@ -27,6 +27,7 @@ | |||
27 | #include <linux/irqbypass.h> | 27 | #include <linux/irqbypass.h> |
28 | #include <linux/hyperv.h> | 28 | #include <linux/hyperv.h> |
29 | 29 | ||
30 | #include <asm/apic.h> | ||
30 | #include <asm/pvclock-abi.h> | 31 | #include <asm/pvclock-abi.h> |
31 | #include <asm/desc.h> | 32 | #include <asm/desc.h> |
32 | #include <asm/mtrr.h> | 33 | #include <asm/mtrr.h> |
@@ -1368,4 +1369,14 @@ static inline void kvm_arch_vcpu_unblocking(struct kvm_vcpu *vcpu) | |||
1368 | 1369 | ||
1369 | static inline void kvm_arch_vcpu_block_finish(struct kvm_vcpu *vcpu) {} | 1370 | static inline void kvm_arch_vcpu_block_finish(struct kvm_vcpu *vcpu) {} |
1370 | 1371 | ||
1372 | static inline int kvm_cpu_get_apicid(int mps_cpu) | ||
1373 | { | ||
1374 | #ifdef CONFIG_X86_LOCAL_APIC | ||
1375 | return __default_cpu_present_to_apicid(mps_cpu); | ||
1376 | #else | ||
1377 | WARN_ON_ONCE(1); | ||
1378 | return BAD_APICID; | ||
1379 | #endif | ||
1380 | } | ||
1381 | |||
1371 | #endif /* _ASM_X86_KVM_HOST_H */ | 1382 | #endif /* _ASM_X86_KVM_HOST_H */ |