Add vhost_ops to vhost_dev struct and replace all relevant ioctls
[qemu/kevin.git] / include / hw / virtio / vhost-backend.h
blob14e5878318020426ceef36eb6cc721d366ad3b7a
1 /*
2 * vhost-backend
4 * Copyright (c) 2013 Virtual Open Systems Sarl.
6 * This work is licensed under the terms of the GNU GPL, version 2 or later.
7 * See the COPYING file in the top-level directory.
9 */
11 #ifndef VHOST_BACKEND_H_
12 #define VHOST_BACKEND_H_
14 struct vhost_dev;
16 typedef int (*vhost_call)(struct vhost_dev *dev, unsigned long int request,
17 void *arg);
18 typedef int (*vhost_backend_init)(struct vhost_dev *dev, void *opaque);
19 typedef int (*vhost_backend_cleanup)(struct vhost_dev *dev);
21 typedef struct VhostOps {
22 vhost_call vhost_call;
23 vhost_backend_init vhost_backend_init;
24 vhost_backend_cleanup vhost_backend_cleanup;
25 } VhostOps;
27 #endif /* VHOST_BACKEND_H_ */