diff options
author | Alexander Graf <agraf@suse.de> | 2010-11-25 04:25:44 -0500 |
---|---|---|
committer | Avi Kivity <avi@redhat.com> | 2011-01-12 04:29:42 -0500 |
commit | 27923eb19c5d1197bd9d1472abdc2e749f21387a (patch) | |
tree | bfb6837f34ea815a06e37f3021407d072e6cf8d7 /include | |
parent | 586f9607962cd982293759a4e95ff06e75be5225 (diff) |
KVM: PPC: Fix compile warning
KVM compilation fails with the following warning:
include/linux/kvm_host.h: In function 'kvm_irq_routing_update':
include/linux/kvm_host.h:679:2: error: 'struct kvm' has no member named 'irq_routing'
That function is only used and reasonable to have on systems that implement
an in-kernel interrupt chip. PPC doesn't.
Fix by #ifdef'ing it out when no irqchip is available.
Signed-off-by: Alexander Graf <agraf@suse.de>
Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/kvm_host.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h index f17beae3cca0..da0794f707f6 100644 --- a/include/linux/kvm_host.h +++ b/include/linux/kvm_host.h | |||
@@ -673,11 +673,13 @@ static inline int kvm_irqfd(struct kvm *kvm, int fd, int gsi, int flags) | |||
673 | 673 | ||
674 | static inline void kvm_irqfd_release(struct kvm *kvm) {} | 674 | static inline void kvm_irqfd_release(struct kvm *kvm) {} |
675 | 675 | ||
676 | #ifdef CONFIG_HAVE_KVM_IRQCHIP | ||
676 | static inline void kvm_irq_routing_update(struct kvm *kvm, | 677 | static inline void kvm_irq_routing_update(struct kvm *kvm, |
677 | struct kvm_irq_routing_table *irq_rt) | 678 | struct kvm_irq_routing_table *irq_rt) |
678 | { | 679 | { |
679 | rcu_assign_pointer(kvm->irq_routing, irq_rt); | 680 | rcu_assign_pointer(kvm->irq_routing, irq_rt); |
680 | } | 681 | } |
682 | #endif | ||
681 | 683 | ||
682 | static inline int kvm_ioeventfd(struct kvm *kvm, struct kvm_ioeventfd *args) | 684 | static inline int kvm_ioeventfd(struct kvm *kvm, struct kvm_ioeventfd *args) |
683 | { | 685 | { |