aboutsummaryrefslogtreecommitdiff
path: root/kvm-all.c
diff options
context:
space:
mode:
authorAlexander Graf <agraf@suse.de>2012-01-25 18:28:05 +0100
committerAlexander Graf <agraf@suse.de>2012-02-02 02:47:46 +0100
commita9c5eb0db1739d53e7a3b1491e496eb25d3db3f4 (patch)
tree4318aeeef63014bcd9fecab490a5f2f822c46cba /kvm-all.c
parent21a0b6ed1dd9f1d8e3d953954847776c8697bd99 (diff)
downloadqemu-a9c5eb0db1739d53e7a3b1491e496eb25d3db3f4.zip
qemu-a9c5eb0db1739d53e7a3b1491e496eb25d3db3f4.tar.gz
qemu-a9c5eb0db1739d53e7a3b1491e496eb25d3db3f4.tar.bz2
KVM: Fix compilation on non-x86
Commit 84b058d broke compilation for KVM on non-x86 targets, which don't have KVM_CAP_IRQ_ROUTING defined. Fix by not using the unavailable constant when it's not around. Signed-off-by: Alexander Graf <agraf@suse.de>
Diffstat (limited to 'kvm-all.c')
-rw-r--r--kvm-all.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/kvm-all.c b/kvm-all.c
index 7d4e544..0b87658 100644
--- a/kvm-all.c
+++ b/kvm-all.c
@@ -1306,7 +1306,11 @@ int kvm_has_many_ioeventfds(void)
int kvm_has_gsi_routing(void)
{
+#ifdef KVM_CAP_IRQ_ROUTING
return kvm_check_extension(kvm_state, KVM_CAP_IRQ_ROUTING);
+#else
+ return false;
+#endif
}
int kvm_allows_irq0_override(void)