summary refs log tree commit diff stats
path: root/contrib/libvhost-user/libvhost-user-glib.h
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2017-10-11 13:10:36 +0100
committerPeter Maydell <peter.maydell@linaro.org>2017-10-11 13:10:36 +0100
commitbac960832015bf4c4c1b873011612e2675e4464c (patch)
tree6b29e22c8a468f11d6ddded18d6c33750eb1be7b /contrib/libvhost-user/libvhost-user-glib.h
parente74c0cfa57323e5806894c65086f411112168820 (diff)
parent53a2e1b523e9015423583e431f4229a0ad35e6cd (diff)
downloadfocaccia-qemu-bac960832015bf4c4c1b873011612e2675e4464c.tar.gz
focaccia-qemu-bac960832015bf4c4c1b873011612e2675e4464c.zip
Merge remote-tracking branch 'remotes/elmarco/tags/vus-pull-request' into staging
# gpg: Signature made Tue 10 Oct 2017 22:33:56 BST
# gpg:                using RSA key 0xDAE8E10975969CE5
# gpg: Good signature from "Marc-André Lureau <marcandre.lureau@redhat.com>"
# gpg:                 aka "Marc-André Lureau <marcandre.lureau@gmail.com>"
# gpg: WARNING: This key is not certified with sufficiently trusted signatures!
# gpg:          It is not certain that the signature belongs to the owner.
# Primary key fingerprint: 87A9 BD93 3F87 C606 D276  F62D DAE8 E109 7596 9CE5

* remotes/elmarco/tags/vus-pull-request: (27 commits)
  vhost-user-scsi: remove server_sock from VusDev
  vhost-user-scsi: use libvhost-user glib helper
  libvhost-user: add glib source helper
  vhost-user-scsi: use glib logging
  vhost-user-scsi: simplify source handling
  vhost-user-scsi: drop extra callback pointer
  vhost-user-scsi: don't copy iscsi/scsi-lowlevel.h
  vhost-user-scsi: avoid use of iscsi_ namespace
  vhost-user-scsi: rename VUS types
  vhost-user-scsi: remove unimplemented functions
  vhost-user-scsi: remove VUS_MAX_LUNS
  vhost-user-scsi: remove vdev_scsi_add_iscsi_lun()
  vhost-user-scsi: assert() in iscsi_add_lun()
  vhost-user-scsi: use NULL pointer
  vhost-user-scsi: simplify unix path cleanup
  vhost-user-scsi: remove vdev_scsi_find_by_vu()
  vhost-user-scsi: also free the gtree
  vhost-user-scsi: glib calls that allocate don't return NULL
  vhost-user-scsi: use glib allocation
  vhost-user-scsi: code style fixes
  ...

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'contrib/libvhost-user/libvhost-user-glib.h')
-rw-r--r--contrib/libvhost-user/libvhost-user-glib.h32
1 files changed, 32 insertions, 0 deletions
diff --git a/contrib/libvhost-user/libvhost-user-glib.h b/contrib/libvhost-user/libvhost-user-glib.h
new file mode 100644
index 0000000000..6b2110b94c
--- /dev/null
+++ b/contrib/libvhost-user/libvhost-user-glib.h
@@ -0,0 +1,32 @@
+/*
+ * Vhost User library
+ *
+ * Copyright (c) 2016 Nutanix Inc. All rights reserved.
+ * Copyright (c) 2017 Red Hat, Inc.
+ *
+ * Authors:
+ *  Marc-André Lureau <mlureau@redhat.com>
+ *  Felipe Franciosi <felipe@nutanix.com>
+ *
+ * This work is licensed under the terms of the GNU GPL, version 2 or
+ * later.  See the COPYING file in the top-level directory.
+ */
+
+#ifndef LIBVHOST_USER_GLIB_H
+#define LIBVHOST_USER_GLIB_H
+
+#include <glib.h>
+#include "libvhost-user.h"
+
+typedef struct VugDev {
+    VuDev parent;
+
+    GHashTable *fdmap; /* fd -> gsource */
+    GSource *src;
+} VugDev;
+
+void vug_init(VugDev *dev, int socket,
+              vu_panic_cb panic, const VuDevIface *iface);
+void vug_deinit(VugDev *dev);
+
+#endif /* LIBVHOST_USER_GLIB_H */