diff options
Diffstat (limited to 'arch/x86/kernel/cpu/hypervisor.c')
-rw-r--r-- | arch/x86/kernel/cpu/hypervisor.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/arch/x86/kernel/cpu/hypervisor.c b/arch/x86/kernel/cpu/hypervisor.c index 22226c1bf092..bea8d3e24f50 100644 --- a/arch/x86/kernel/cpu/hypervisor.c +++ b/arch/x86/kernel/cpu/hypervisor.c | |||
@@ -26,6 +26,12 @@ | |||
26 | #include <asm/processor.h> | 26 | #include <asm/processor.h> |
27 | #include <asm/hypervisor.h> | 27 | #include <asm/hypervisor.h> |
28 | 28 | ||
29 | extern const struct hypervisor_x86 x86_hyper_vmware; | ||
30 | extern const struct hypervisor_x86 x86_hyper_ms_hyperv; | ||
31 | extern const struct hypervisor_x86 x86_hyper_xen_pv; | ||
32 | extern const struct hypervisor_x86 x86_hyper_xen_hvm; | ||
33 | extern const struct hypervisor_x86 x86_hyper_kvm; | ||
34 | |||
29 | static const __initconst struct hypervisor_x86 * const hypervisors[] = | 35 | static const __initconst struct hypervisor_x86 * const hypervisors[] = |
30 | { | 36 | { |
31 | #ifdef CONFIG_XEN_PV | 37 | #ifdef CONFIG_XEN_PV |
@@ -41,8 +47,8 @@ static const __initconst struct hypervisor_x86 * const hypervisors[] = | |||
41 | #endif | 47 | #endif |
42 | }; | 48 | }; |
43 | 49 | ||
44 | const struct hypervisor_x86 *x86_hyper; | 50 | enum x86_hypervisor_type x86_hyper_type; |
45 | EXPORT_SYMBOL(x86_hyper); | 51 | EXPORT_SYMBOL(x86_hyper_type); |
46 | 52 | ||
47 | static inline const struct hypervisor_x86 * __init | 53 | static inline const struct hypervisor_x86 * __init |
48 | detect_hypervisor_vendor(void) | 54 | detect_hypervisor_vendor(void) |
@@ -87,6 +93,6 @@ void __init init_hypervisor_platform(void) | |||
87 | copy_array(&h->init, &x86_init.hyper, sizeof(h->init)); | 93 | copy_array(&h->init, &x86_init.hyper, sizeof(h->init)); |
88 | copy_array(&h->runtime, &x86_platform.hyper, sizeof(h->runtime)); | 94 | copy_array(&h->runtime, &x86_platform.hyper, sizeof(h->runtime)); |
89 | 95 | ||
90 | x86_hyper = h; | 96 | x86_hyper_type = h->type; |
91 | x86_init.hyper.init_platform(); | 97 | x86_init.hyper.init_platform(); |
92 | } | 98 | } |