]> git.proxmox.com Git - qemu.git/commitdiff
hyperv: fix build on non-KVM hosts
authorBlue Swirl <blauwirbel@gmail.com>
Mon, 23 Jan 2012 19:59:14 +0000 (19:59 +0000)
committerBlue Swirl <blauwirbel@gmail.com>
Mon, 23 Jan 2012 20:04:51 +0000 (20:04 +0000)
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Makefile.target
target-i386/hyperv.h

index 092565a1e824c16c2d4c4d2cfeac94dcf2e4c7a2..69193d4938d97aafd8c443037a4a795cdfb0a83e 100644 (file)
@@ -201,7 +201,7 @@ obj-$(CONFIG_VGA_CIRRUS) += cirrus_vga.o
 obj-y += memory.o savevm.o
 LIBS+=-lz
 
-obj-i386-y +=hyperv.o
+obj-i386-$(CONFIG_KVM) += hyperv.o
 
 QEMU_CFLAGS += $(VNC_TLS_CFLAGS)
 QEMU_CFLAGS += $(VNC_SASL_CFLAGS)
index 15467bf3970dd684cb369c01dfd454484c9ce6f1..bacb1d43738df00e141c6a1cfaba5142e6015d7b 100644 (file)
@@ -14,7 +14,9 @@
 #define QEMU_HW_HYPERV_H 1
 
 #include "qemu-common.h"
+#ifdef CONFIG_KVM
 #include <asm/hyperv.h>
+#endif
 
 #ifndef HYPERV_SPINLOCK_NEVER_RETRY
 #define HYPERV_SPINLOCK_NEVER_RETRY             0xFFFFFFFF
@@ -24,7 +26,7 @@
 #define KVM_CPUID_SIGNATURE_NEXT                0x40000100
 #endif
 
-#ifndef CONFIG_USER_ONLY
+#if !defined(CONFIG_USER_ONLY) && defined(CONFIG_KVM)
 void hyperv_enable_vapic_recommended(bool val);
 void hyperv_enable_relaxed_timing(bool val);
 void hyperv_set_spinlock_retries(int val);