summaryrefslogtreecommitdiffstats
path: root/include/hw/virtio/vhost-user.h
diff options
context:
space:
mode:
authorMarc-André Lureau2019-03-08 15:04:45 +0100
committerMichael S. Tsirkin2019-03-13 02:22:31 +0100
commit0b99f22461e59ec7a31c75ebc4c057a45dd9e9a5 (patch)
tree142283f1815e944c15717de9ef156e74fcdb5acf /include/hw/virtio/vhost-user.h
parentvhost-user: define conventions for vhost-user backends (diff)
downloadqemu-0b99f22461e59ec7a31c75ebc4c057a45dd9e9a5.tar.gz
qemu-0b99f22461e59ec7a31c75ebc4c057a45dd9e9a5.tar.xz
qemu-0b99f22461e59ec7a31c75ebc4c057a45dd9e9a5.zip
vhost-user: simplify vhost_user_init/vhost_user_cleanup
Take a VhostUserState* that can be pre-allocated, and initialize it with the associated chardev. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: Tiwei Bie <tiwei.bie@intel.com> Message-Id: <20190308140454.32437-4-marcandre.lureau@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'include/hw/virtio/vhost-user.h')
-rw-r--r--include/hw/virtio/vhost-user.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/hw/virtio/vhost-user.h b/include/hw/virtio/vhost-user.h
index fd660393a0..811e325f42 100644
--- a/include/hw/virtio/vhost-user.h
+++ b/include/hw/virtio/vhost-user.h
@@ -22,7 +22,7 @@ typedef struct VhostUserState {
VhostUserHostNotifier notifier[VIRTIO_QUEUE_MAX];
} VhostUserState;
-VhostUserState *vhost_user_init(void);
+bool vhost_user_init(VhostUserState *user, CharBackend *chr, Error **errp);
void vhost_user_cleanup(VhostUserState *user);
#endif