summaryrefslogtreecommitdiff
path: root/kvm.h
diff options
context:
space:
mode:
authorMichael S. Tsirkin <mst@redhat.com>2010-03-17 15:04:49 +0200
committerMarcelo Tosatti <mtosatti@redhat.com>2010-04-06 16:01:34 -0300
commitcb8c9b2318df8846b5dfdc47061e6537000eafed (patch)
treee64630582f2b803ee4eec9fbaed1c669f6e80dda /kvm.h
parent3a172a9f44a5b3037bde1c02c53793477b0fea1e (diff)
kvm: irqfd support
Add API to assign/deassign irqfd to kvm. Add stub so that users do not have to use ifdefs. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Diffstat (limited to 'kvm.h')
-rw-r--r--kvm.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/kvm.h b/kvm.h
index c63e31404..65a4ee2ec 100644
--- a/kvm.h
+++ b/kvm.h
@@ -183,5 +183,15 @@ int kvm_set_ioeventfd_pio_word(int fd, uint16_t adr, uint16_t val, bool assign)
}
#endif
+#if defined(KVM_IRQFD) && defined(CONFIG_KVM)
+int kvm_set_irqfd(int gsi, int fd, bool assigned);
+#else
+static inline
+int kvm_set_irqfd(int gsi, int fd, bool assigned)
+{
+ return -ENOSYS;
+}
+#endif
+
#endif
#endif