aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarc Zyngier <marc.zyngier@arm.com>2012-06-15 15:07:02 -0400
committerAvi Kivity <avi@redhat.com>2012-06-18 09:06:35 -0400
commit9900b4b48b095895cf962054e45aafa49ef70f74 (patch)
treed831176b62979612b2d4e5504d2d2de1ddee3817
parentdcce0489477f07ac1331aee71f18d6274e19a9c1 (diff)
KVM: use KVM_CAP_IRQ_ROUTING to protect the routing related code
The KVM code sometimes uses CONFIG_HAVE_KVM_IRQCHIP to protect code that is related to IRQ routing, which not all in-kernel irqchips may support. Use KVM_CAP_IRQ_ROUTING instead. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Christoffer Dall <c.dall@virtualopensystems.com> Signed-off-by: Avi Kivity <avi@redhat.com>
-rw-r--r--include/linux/kvm_host.h2
-rw-r--r--virt/kvm/kvm_main.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h
index 27ac8a4767fa..c7f77876c9b3 100644
--- a/include/linux/kvm_host.h
+++ b/include/linux/kvm_host.h
@@ -802,7 +802,7 @@ static inline int mmu_notifier_retry(struct kvm_vcpu *vcpu, unsigned long mmu_se
802} 802}
803#endif 803#endif
804 804
805#ifdef CONFIG_HAVE_KVM_IRQCHIP 805#ifdef KVM_CAP_IRQ_ROUTING
806 806
807#define KVM_MAX_IRQ_ROUTES 1024 807#define KVM_MAX_IRQ_ROUTES 1024
808 808
diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c
index 02cb440f802d..636bd08bb399 100644
--- a/virt/kvm/kvm_main.c
+++ b/virt/kvm/kvm_main.c
@@ -2225,7 +2225,7 @@ static long kvm_dev_ioctl_check_extension_generic(long arg)
2225 case KVM_CAP_SIGNAL_MSI: 2225 case KVM_CAP_SIGNAL_MSI:
2226#endif 2226#endif
2227 return 1; 2227 return 1;
2228#ifdef CONFIG_HAVE_KVM_IRQCHIP 2228#ifdef KVM_CAP_IRQ_ROUTING
2229 case KVM_CAP_IRQ_ROUTING: 2229 case KVM_CAP_IRQ_ROUTING:
2230 return KVM_MAX_IRQ_ROUTES; 2230 return KVM_MAX_IRQ_ROUTES;
2231#endif 2231#endif