aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2013-04-30 11:41:21 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2013-04-30 11:41:21 -0400
commit1e2f5b598aa56c3978c2e623f72e9656a565c6c9 (patch)
tree31b3a7555ac7c1d9a856adc0436ed9943c9cab36
parentf9b3bcfbc43ac80f2019a5093ad9a1e624e611b1 (diff)
parent4d681be3c33dd74efffbe2a8f70634f7128602ec (diff)
Merge branch 'x86-paravirt-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull x86 paravirt update from Ingo Molnar: "Various paravirtualization related changes - the biggest one makes guest support optional via CONFIG_HYPERVISOR_GUEST" * 'x86-paravirt-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86, wakeup, sleep: Use pvops functions for changing GDT entries x86, xen, gdt: Remove the pvops variant of store_gdt. x86-32, gdt: Store/load GDT for ACPI S3 or hibernation/resume path is not needed x86-64, gdt: Store/load GDT for ACPI S3 or hibernate/resume path is not needed. x86: Make Linux guest support optional x86, Kconfig: Move PARAVIRT_DEBUG into the paravirt menu
-rw-r--r--arch/x86/Kconfig89
-rw-r--r--arch/x86/include/asm/hypervisor.h16
-rw-r--r--arch/x86/include/asm/paravirt.h4
-rw-r--r--arch/x86/include/asm/paravirt_types.h2
-rw-r--r--arch/x86/include/asm/suspend_32.h1
-rw-r--r--arch/x86/include/asm/suspend_64.h3
-rw-r--r--arch/x86/kernel/acpi/sleep.c2
-rw-r--r--arch/x86/kernel/acpi/wakeup_32.S3
-rw-r--r--arch/x86/kernel/cpu/Makefile3
-rw-r--r--arch/x86/kernel/doublefault_32.c2
-rw-r--r--arch/x86/kernel/paravirt.c1
-rw-r--r--arch/x86/kvm/vmx.c2
-rw-r--r--arch/x86/lguest/Kconfig3
-rw-r--r--arch/x86/power/cpu.c13
-rw-r--r--arch/x86/xen/Kconfig2
-rw-r--r--arch/x86/xen/enlighten.c1
-rw-r--r--drivers/hv/Kconfig2
-rw-r--r--drivers/misc/Kconfig2
18 files changed, 73 insertions, 78 deletions
diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index e93ccb9b1cc1..05b057dca4a7 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -387,7 +387,7 @@ config X86_NUMACHIP
387 387
388config X86_VSMP 388config X86_VSMP
389 bool "ScaleMP vSMP" 389 bool "ScaleMP vSMP"
390 select PARAVIRT_GUEST 390 select HYPERVISOR_GUEST
391 select PARAVIRT 391 select PARAVIRT
392 depends on X86_64 && PCI 392 depends on X86_64 && PCI
393 depends on X86_EXTENDED_PLATFORM 393 depends on X86_EXTENDED_PLATFORM
@@ -594,44 +594,17 @@ config SCHED_OMIT_FRAME_POINTER
594 594
595 If in doubt, say "Y". 595 If in doubt, say "Y".
596 596
597menuconfig PARAVIRT_GUEST 597menuconfig HYPERVISOR_GUEST
598 bool "Paravirtualized guest support" 598 bool "Linux guest support"
599 ---help--- 599 ---help---
600 Say Y here to get to see options related to running Linux under 600 Say Y here to enable options for running Linux under various hyper-
601 various hypervisors. This option alone does not add any kernel code. 601 visors. This option enables basic hypervisor detection and platform
602 setup.
602 603
603 If you say N, all options in this submenu will be skipped and disabled. 604 If you say N, all options in this submenu will be skipped and
605 disabled, and Linux guest support won't be built in.
604 606
605if PARAVIRT_GUEST 607if HYPERVISOR_GUEST
606
607config PARAVIRT_TIME_ACCOUNTING
608 bool "Paravirtual steal time accounting"
609 select PARAVIRT
610 default n
611 ---help---
612 Select this option to enable fine granularity task steal time
613 accounting. Time spent executing other tasks in parallel with
614 the current vCPU is discounted from the vCPU power. To account for
615 that, there can be a small performance impact.
616
617 If in doubt, say N here.
618
619source "arch/x86/xen/Kconfig"
620
621config KVM_GUEST
622 bool "KVM Guest support (including kvmclock)"
623 select PARAVIRT
624 select PARAVIRT
625 select PARAVIRT_CLOCK
626 default y if PARAVIRT_GUEST
627 ---help---
628 This option enables various optimizations for running under the KVM
629 hypervisor. It includes a paravirtualized clock, so that instead
630 of relying on a PIT (or probably other) emulation by the
631 underlying device model, the host provides the guest with
632 timing infrastructure such as time of day, and system time
633
634source "arch/x86/lguest/Kconfig"
635 608
636config PARAVIRT 609config PARAVIRT
637 bool "Enable paravirtualization code" 610 bool "Enable paravirtualization code"
@@ -641,6 +614,13 @@ config PARAVIRT
641 over full virtualization. However, when run without a hypervisor 614 over full virtualization. However, when run without a hypervisor
642 the kernel is theoretically slower and slightly larger. 615 the kernel is theoretically slower and slightly larger.
643 616
617config PARAVIRT_DEBUG
618 bool "paravirt-ops debugging"
619 depends on PARAVIRT && DEBUG_KERNEL
620 ---help---
621 Enable to debug paravirt_ops internals. Specifically, BUG if
622 a paravirt_op is missing when it is called.
623
644config PARAVIRT_SPINLOCKS 624config PARAVIRT_SPINLOCKS
645 bool "Paravirtualization layer for spinlocks" 625 bool "Paravirtualization layer for spinlocks"
646 depends on PARAVIRT && SMP 626 depends on PARAVIRT && SMP
@@ -654,17 +634,38 @@ config PARAVIRT_SPINLOCKS
654 634
655 If you are unsure how to answer this question, answer N. 635 If you are unsure how to answer this question, answer N.
656 636
657config PARAVIRT_CLOCK 637source "arch/x86/xen/Kconfig"
658 bool
659 638
660endif 639config KVM_GUEST
640 bool "KVM Guest support (including kvmclock)"
641 depends on PARAVIRT
642 select PARAVIRT_CLOCK
643 default y
644 ---help---
645 This option enables various optimizations for running under the KVM
646 hypervisor. It includes a paravirtualized clock, so that instead
647 of relying on a PIT (or probably other) emulation by the
648 underlying device model, the host provides the guest with
649 timing infrastructure such as time of day, and system time
661 650
662config PARAVIRT_DEBUG 651source "arch/x86/lguest/Kconfig"
663 bool "paravirt-ops debugging" 652
664 depends on PARAVIRT && DEBUG_KERNEL 653config PARAVIRT_TIME_ACCOUNTING
654 bool "Paravirtual steal time accounting"
655 depends on PARAVIRT
656 default n
665 ---help--- 657 ---help---
666 Enable to debug paravirt_ops internals. Specifically, BUG if 658 Select this option to enable fine granularity task steal time
667 a paravirt_op is missing when it is called. 659 accounting. Time spent executing other tasks in parallel with
660 the current vCPU is discounted from the vCPU power. To account for
661 that, there can be a small performance impact.
662
663 If in doubt, say N here.
664
665config PARAVIRT_CLOCK
666 bool
667
668endif #HYPERVISOR_GUEST
668 669
669config NO_BOOTMEM 670config NO_BOOTMEM
670 def_bool y 671 def_bool y
diff --git a/arch/x86/include/asm/hypervisor.h b/arch/x86/include/asm/hypervisor.h
index 86095ed14135..2d4b5e6107cd 100644
--- a/arch/x86/include/asm/hypervisor.h
+++ b/arch/x86/include/asm/hypervisor.h
@@ -20,13 +20,11 @@
20#ifndef _ASM_X86_HYPERVISOR_H 20#ifndef _ASM_X86_HYPERVISOR_H
21#define _ASM_X86_HYPERVISOR_H 21#define _ASM_X86_HYPERVISOR_H
22 22
23#ifdef CONFIG_HYPERVISOR_GUEST
24
23#include <asm/kvm_para.h> 25#include <asm/kvm_para.h>
24#include <asm/xen/hypervisor.h> 26#include <asm/xen/hypervisor.h>
25 27
26extern void init_hypervisor(struct cpuinfo_x86 *c);
27extern void init_hypervisor_platform(void);
28extern bool hypervisor_x2apic_available(void);
29
30/* 28/*
31 * x86 hypervisor information 29 * x86 hypervisor information
32 */ 30 */
@@ -55,4 +53,12 @@ extern const struct hypervisor_x86 x86_hyper_ms_hyperv;
55extern const struct hypervisor_x86 x86_hyper_xen_hvm; 53extern const struct hypervisor_x86 x86_hyper_xen_hvm;
56extern const struct hypervisor_x86 x86_hyper_kvm; 54extern const struct hypervisor_x86 x86_hyper_kvm;
57 55
58#endif 56extern void init_hypervisor(struct cpuinfo_x86 *c);
57extern void init_hypervisor_platform(void);
58extern bool hypervisor_x2apic_available(void);
59#else
60static inline void init_hypervisor(struct cpuinfo_x86 *c) { }
61static inline void init_hypervisor_platform(void) { }
62static inline bool hypervisor_x2apic_available(void) { return false; }
63#endif /* CONFIG_HYPERVISOR_GUEST */
64#endif /* _ASM_X86_HYPERVISOR_H */
diff --git a/arch/x86/include/asm/paravirt.h b/arch/x86/include/asm/paravirt.h
index 7361e47db79f..cfdc9ee4c900 100644
--- a/arch/x86/include/asm/paravirt.h
+++ b/arch/x86/include/asm/paravirt.h
@@ -262,10 +262,6 @@ static inline void set_ldt(const void *addr, unsigned entries)
262{ 262{
263 PVOP_VCALL2(pv_cpu_ops.set_ldt, addr, entries); 263 PVOP_VCALL2(pv_cpu_ops.set_ldt, addr, entries);
264} 264}
265static inline void store_gdt(struct desc_ptr *dtr)
266{
267 PVOP_VCALL1(pv_cpu_ops.store_gdt, dtr);
268}
269static inline void store_idt(struct desc_ptr *dtr) 265static inline void store_idt(struct desc_ptr *dtr)
270{ 266{
271 PVOP_VCALL1(pv_cpu_ops.store_idt, dtr); 267 PVOP_VCALL1(pv_cpu_ops.store_idt, dtr);
diff --git a/arch/x86/include/asm/paravirt_types.h b/arch/x86/include/asm/paravirt_types.h
index b3b0ec1dac86..0db1fcac668c 100644
--- a/arch/x86/include/asm/paravirt_types.h
+++ b/arch/x86/include/asm/paravirt_types.h
@@ -123,7 +123,7 @@ struct pv_cpu_ops {
123 void (*load_tr_desc)(void); 123 void (*load_tr_desc)(void);
124 void (*load_gdt)(const struct desc_ptr *); 124 void (*load_gdt)(const struct desc_ptr *);
125 void (*load_idt)(const struct desc_ptr *); 125 void (*load_idt)(const struct desc_ptr *);
126 void (*store_gdt)(struct desc_ptr *); 126 /* store_gdt has been removed. */
127 void (*store_idt)(struct desc_ptr *); 127 void (*store_idt)(struct desc_ptr *);
128 void (*set_ldt)(const void *desc, unsigned entries); 128 void (*set_ldt)(const void *desc, unsigned entries);
129 unsigned long (*store_tr)(void); 129 unsigned long (*store_tr)(void);
diff --git a/arch/x86/include/asm/suspend_32.h b/arch/x86/include/asm/suspend_32.h
index 487055c8c1aa..f6064b7385b0 100644
--- a/arch/x86/include/asm/suspend_32.h
+++ b/arch/x86/include/asm/suspend_32.h
@@ -15,7 +15,6 @@ struct saved_context {
15 unsigned long cr0, cr2, cr3, cr4; 15 unsigned long cr0, cr2, cr3, cr4;
16 u64 misc_enable; 16 u64 misc_enable;
17 bool misc_enable_saved; 17 bool misc_enable_saved;
18 struct desc_ptr gdt;
19 struct desc_ptr idt; 18 struct desc_ptr idt;
20 u16 ldt; 19 u16 ldt;
21 u16 tss; 20 u16 tss;
diff --git a/arch/x86/include/asm/suspend_64.h b/arch/x86/include/asm/suspend_64.h
index 09b0bf104156..97b84e08a211 100644
--- a/arch/x86/include/asm/suspend_64.h
+++ b/arch/x86/include/asm/suspend_64.h
@@ -25,9 +25,6 @@ struct saved_context {
25 u64 misc_enable; 25 u64 misc_enable;
26 bool misc_enable_saved; 26 bool misc_enable_saved;
27 unsigned long efer; 27 unsigned long efer;
28 u16 gdt_pad;
29 u16 gdt_limit;
30 unsigned long gdt_base;
31 u16 idt_pad; 28 u16 idt_pad;
32 u16 idt_limit; 29 u16 idt_limit;
33 unsigned long idt_base; 30 unsigned long idt_base;
diff --git a/arch/x86/kernel/acpi/sleep.c b/arch/x86/kernel/acpi/sleep.c
index 0532f5d6e4ef..b44577bc9744 100644
--- a/arch/x86/kernel/acpi/sleep.c
+++ b/arch/x86/kernel/acpi/sleep.c
@@ -46,7 +46,7 @@ int acpi_suspend_lowlevel(void)
46 header->pmode_behavior = 0; 46 header->pmode_behavior = 0;
47 47
48#ifndef CONFIG_64BIT 48#ifndef CONFIG_64BIT
49 store_gdt((struct desc_ptr *)&header->pmode_gdt); 49 native_store_gdt((struct desc_ptr *)&header->pmode_gdt);
50 50
51 if (!rdmsr_safe(MSR_EFER, 51 if (!rdmsr_safe(MSR_EFER,
52 &header->pmode_efer_low, 52 &header->pmode_efer_low,
diff --git a/arch/x86/kernel/acpi/wakeup_32.S b/arch/x86/kernel/acpi/wakeup_32.S
index ced4638c8341..d1daa66ab162 100644
--- a/arch/x86/kernel/acpi/wakeup_32.S
+++ b/arch/x86/kernel/acpi/wakeup_32.S
@@ -18,7 +18,6 @@ wakeup_pmode_return:
18 movw %ax, %gs 18 movw %ax, %gs
19 19
20 # reload the gdt, as we need the full 32 bit address 20 # reload the gdt, as we need the full 32 bit address
21 lgdt saved_gdt
22 lidt saved_idt 21 lidt saved_idt
23 lldt saved_ldt 22 lldt saved_ldt
24 ljmp $(__KERNEL_CS), $1f 23 ljmp $(__KERNEL_CS), $1f
@@ -44,7 +43,6 @@ bogus_magic:
44 43
45 44
46save_registers: 45save_registers:
47 sgdt saved_gdt
48 sidt saved_idt 46 sidt saved_idt
49 sldt saved_ldt 47 sldt saved_ldt
50 str saved_tss 48 str saved_tss
@@ -93,7 +91,6 @@ ENTRY(saved_magic) .long 0
93ENTRY(saved_eip) .long 0 91ENTRY(saved_eip) .long 0
94 92
95# saved registers 93# saved registers
96saved_gdt: .long 0,0
97saved_idt: .long 0,0 94saved_idt: .long 0,0
98saved_ldt: .long 0 95saved_ldt: .long 0
99saved_tss: .long 0 96saved_tss: .long 0
diff --git a/arch/x86/kernel/cpu/Makefile b/arch/x86/kernel/cpu/Makefile
index deef0399fc78..b0684e4a73aa 100644
--- a/arch/x86/kernel/cpu/Makefile
+++ b/arch/x86/kernel/cpu/Makefile
@@ -14,7 +14,6 @@ CFLAGS_common.o := $(nostackp)
14 14
15obj-y := intel_cacheinfo.o scattered.o topology.o 15obj-y := intel_cacheinfo.o scattered.o topology.o
16obj-y += proc.o capflags.o powerflags.o common.o 16obj-y += proc.o capflags.o powerflags.o common.o
17obj-y += vmware.o hypervisor.o mshyperv.o
18obj-y += rdrand.o 17obj-y += rdrand.o
19obj-y += match.o 18obj-y += match.o
20 19
@@ -42,6 +41,8 @@ obj-$(CONFIG_MTRR) += mtrr/
42 41
43obj-$(CONFIG_X86_LOCAL_APIC) += perfctr-watchdog.o perf_event_amd_ibs.o 42obj-$(CONFIG_X86_LOCAL_APIC) += perfctr-watchdog.o perf_event_amd_ibs.o
44 43
44obj-$(CONFIG_HYPERVISOR_GUEST) += vmware.o hypervisor.o mshyperv.o
45
45quiet_cmd_mkcapflags = MKCAP $@ 46quiet_cmd_mkcapflags = MKCAP $@
46 cmd_mkcapflags = $(CONFIG_SHELL) $(srctree)/$(src)/mkcapflags.sh $< $@ 47 cmd_mkcapflags = $(CONFIG_SHELL) $(srctree)/$(src)/mkcapflags.sh $< $@
47 48
diff --git a/arch/x86/kernel/doublefault_32.c b/arch/x86/kernel/doublefault_32.c
index 37250fe490b1..155a13f33ed8 100644
--- a/arch/x86/kernel/doublefault_32.c
+++ b/arch/x86/kernel/doublefault_32.c
@@ -20,7 +20,7 @@ static void doublefault_fn(void)
20 struct desc_ptr gdt_desc = {0, 0}; 20 struct desc_ptr gdt_desc = {0, 0};
21 unsigned long gdt, tss; 21 unsigned long gdt, tss;
22 22
23 store_gdt(&gdt_desc); 23 native_store_gdt(&gdt_desc);
24 gdt = gdt_desc.address; 24 gdt = gdt_desc.address;
25 25
26 printk(KERN_EMERG "PANIC: double fault, gdt at %08lx [%d bytes]\n", gdt, gdt_desc.size); 26 printk(KERN_EMERG "PANIC: double fault, gdt at %08lx [%d bytes]\n", gdt, gdt_desc.size);
diff --git a/arch/x86/kernel/paravirt.c b/arch/x86/kernel/paravirt.c
index 8bfb335f74bb..cd6de64cc480 100644
--- a/arch/x86/kernel/paravirt.c
+++ b/arch/x86/kernel/paravirt.c
@@ -360,7 +360,6 @@ struct pv_cpu_ops pv_cpu_ops = {
360 .set_ldt = native_set_ldt, 360 .set_ldt = native_set_ldt,
361 .load_gdt = native_load_gdt, 361 .load_gdt = native_load_gdt,
362 .load_idt = native_load_idt, 362 .load_idt = native_load_idt,
363 .store_gdt = native_store_gdt,
364 .store_idt = native_store_idt, 363 .store_idt = native_store_idt,
365 .store_tr = native_store_tr, 364 .store_tr = native_store_tr,
366 .load_tls = native_load_tls, 365 .load_tls = native_load_tls,
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index 6667042714cc..867b81037f96 100644
--- a/arch/x86/kvm/vmx.c
+++ b/arch/x86/kvm/vmx.c
@@ -2459,7 +2459,7 @@ static int hardware_enable(void *garbage)
2459 ept_sync_global(); 2459 ept_sync_global();
2460 } 2460 }
2461 2461
2462 store_gdt(&__get_cpu_var(host_gdt)); 2462 native_store_gdt(&__get_cpu_var(host_gdt));
2463 2463
2464 return 0; 2464 return 0;
2465} 2465}
diff --git a/arch/x86/lguest/Kconfig b/arch/x86/lguest/Kconfig
index 29043d2048a0..4a0890f815c4 100644
--- a/arch/x86/lguest/Kconfig
+++ b/arch/x86/lguest/Kconfig
@@ -1,7 +1,6 @@
1config LGUEST_GUEST 1config LGUEST_GUEST
2 bool "Lguest guest support" 2 bool "Lguest guest support"
3 select PARAVIRT 3 depends on X86_32 && PARAVIRT
4 depends on X86_32
5 select TTY 4 select TTY
6 select VIRTUALIZATION 5 select VIRTUALIZATION
7 select VIRTIO 6 select VIRTIO
diff --git a/arch/x86/power/cpu.c b/arch/x86/power/cpu.c
index 3c68768d7a75..6d6e907cee46 100644
--- a/arch/x86/power/cpu.c
+++ b/arch/x86/power/cpu.c
@@ -62,11 +62,9 @@ static void __save_processor_state(struct saved_context *ctxt)
62 * descriptor tables 62 * descriptor tables
63 */ 63 */
64#ifdef CONFIG_X86_32 64#ifdef CONFIG_X86_32
65 store_gdt(&ctxt->gdt);
66 store_idt(&ctxt->idt); 65 store_idt(&ctxt->idt);
67#else 66#else
68/* CONFIG_X86_64 */ 67/* CONFIG_X86_64 */
69 store_gdt((struct desc_ptr *)&ctxt->gdt_limit);
70 store_idt((struct desc_ptr *)&ctxt->idt_limit); 68 store_idt((struct desc_ptr *)&ctxt->idt_limit);
71#endif 69#endif
72 store_tr(ctxt->tr); 70 store_tr(ctxt->tr);
@@ -135,7 +133,10 @@ static void fix_processor_context(void)
135{ 133{
136 int cpu = smp_processor_id(); 134 int cpu = smp_processor_id();
137 struct tss_struct *t = &per_cpu(init_tss, cpu); 135 struct tss_struct *t = &per_cpu(init_tss, cpu);
138 136#ifdef CONFIG_X86_64
137 struct desc_struct *desc = get_cpu_gdt_table(cpu);
138 tss_desc tss;
139#endif
139 set_tss_desc(cpu, t); /* 140 set_tss_desc(cpu, t); /*
140 * This just modifies memory; should not be 141 * This just modifies memory; should not be
141 * necessary. But... This is necessary, because 142 * necessary. But... This is necessary, because
@@ -144,7 +145,9 @@ static void fix_processor_context(void)
144 */ 145 */
145 146
146#ifdef CONFIG_X86_64 147#ifdef CONFIG_X86_64
147 get_cpu_gdt_table(cpu)[GDT_ENTRY_TSS].type = 9; 148 memcpy(&tss, &desc[GDT_ENTRY_TSS], sizeof(tss_desc));
149 tss.type = 0x9; /* The available 64-bit TSS (see AMD vol 2, pg 91 */
150 write_gdt_entry(desc, GDT_ENTRY_TSS, &tss, DESC_TSS);
148 151
149 syscall_init(); /* This sets MSR_*STAR and related */ 152 syscall_init(); /* This sets MSR_*STAR and related */
150#endif 153#endif
@@ -183,11 +186,9 @@ static void __restore_processor_state(struct saved_context *ctxt)
183 * ltr is done i fix_processor_context(). 186 * ltr is done i fix_processor_context().
184 */ 187 */
185#ifdef CONFIG_X86_32 188#ifdef CONFIG_X86_32
186 load_gdt(&ctxt->gdt);
187 load_idt(&ctxt->idt); 189 load_idt(&ctxt->idt);
188#else 190#else
189/* CONFIG_X86_64 */ 191/* CONFIG_X86_64 */
190 load_gdt((const struct desc_ptr *)&ctxt->gdt_limit);
191 load_idt((const struct desc_ptr *)&ctxt->idt_limit); 192 load_idt((const struct desc_ptr *)&ctxt->idt_limit);
192#endif 193#endif
193 194
diff --git a/arch/x86/xen/Kconfig b/arch/x86/xen/Kconfig
index 131dacd2748a..1a3c76505649 100644
--- a/arch/x86/xen/Kconfig
+++ b/arch/x86/xen/Kconfig
@@ -4,7 +4,7 @@
4 4
5config XEN 5config XEN
6 bool "Xen guest support" 6 bool "Xen guest support"
7 select PARAVIRT 7 depends on PARAVIRT
8 select PARAVIRT_CLOCK 8 select PARAVIRT_CLOCK
9 select XEN_HAVE_PVMMU 9 select XEN_HAVE_PVMMU
10 depends on X86_64 || (X86_32 && X86_PAE && !X86_VISWS) 10 depends on X86_64 || (X86_32 && X86_PAE && !X86_VISWS)
diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c
index ddbd54a9b845..53d4f680c9b5 100644
--- a/arch/x86/xen/enlighten.c
+++ b/arch/x86/xen/enlighten.c
@@ -1221,7 +1221,6 @@ static const struct pv_cpu_ops xen_cpu_ops __initconst = {
1221 .alloc_ldt = xen_alloc_ldt, 1221 .alloc_ldt = xen_alloc_ldt,
1222 .free_ldt = xen_free_ldt, 1222 .free_ldt = xen_free_ldt,
1223 1223
1224 .store_gdt = native_store_gdt,
1225 .store_idt = native_store_idt, 1224 .store_idt = native_store_idt,
1226 .store_tr = xen_store_tr, 1225 .store_tr = xen_store_tr,
1227 1226
diff --git a/drivers/hv/Kconfig b/drivers/hv/Kconfig
index 64630f15f181..0403b51d20ba 100644
--- a/drivers/hv/Kconfig
+++ b/drivers/hv/Kconfig
@@ -2,7 +2,7 @@ menu "Microsoft Hyper-V guest support"
2 2
3config HYPERV 3config HYPERV
4 tristate "Microsoft Hyper-V client drivers" 4 tristate "Microsoft Hyper-V client drivers"
5 depends on X86 && ACPI && PCI && X86_LOCAL_APIC 5 depends on X86 && ACPI && PCI && X86_LOCAL_APIC && HYPERVISOR_GUEST
6 help 6 help
7 Select this option to run Linux as a Hyper-V client operating 7 Select this option to run Linux as a Hyper-V client operating
8 system. 8 system.
diff --git a/drivers/misc/Kconfig b/drivers/misc/Kconfig
index 3659d00efdc5..c002d8660e30 100644
--- a/drivers/misc/Kconfig
+++ b/drivers/misc/Kconfig
@@ -426,7 +426,7 @@ config TI_DAC7512
426 426
427config VMWARE_BALLOON 427config VMWARE_BALLOON
428 tristate "VMware Balloon Driver" 428 tristate "VMware Balloon Driver"
429 depends on X86 429 depends on X86 && HYPERVISOR_GUEST
430 help 430 help
431 This is VMware physical memory management driver which acts 431 This is VMware physical memory management driver which acts
432 like a "balloon" that can be inflated to reclaim physical pages 432 like a "balloon" that can be inflated to reclaim physical pages