Message ID | 1242574999-20887-2-git-send-email-aliguori@us.ibm.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Anthony Liguori wrote: > From: Gleb Natapov <gleb@redhat.com> > > Fixes builds with older kernel headers. > Since we build with a specific set of headers now (rather that 'make sync'), this isn't necessary.
diff --git a/kvm/libkvm/libkvm.c b/kvm/libkvm/libkvm.c index 0ac1c28..7c65f31 100644 --- a/kvm/libkvm/libkvm.c +++ b/kvm/libkvm/libkvm.c @@ -667,9 +667,14 @@ int kvm_set_irq_level(kvm_context_t kvm, int irq, int level, int *status) if (r == -1) perror("kvm_set_irq_level"); - if (status) + if (status) { +#ifdef KVM_CAP_IRQ_INJECT_STATUS *status = (kvm->irqchip_inject_ioctl == KVM_IRQ_LINE) ? 1 : event.status; +#else + *status = 1; +#endif + } return 1; }