xref: /qemu/include/hw/virtio/vhost-backend.h (revision 24d1eb33eb2ccd995a845a4d4b793e2619a9e460)
1 /*
2  * vhost-backend
3  *
4  * Copyright (c) 2013 Virtual Open Systems Sarl.
5  *
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.
8  *
9  */
10 
11 #ifndef VHOST_BACKEND_H_
12 #define VHOST_BACKEND_H_
13 
14 struct vhost_dev;
15 
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);
20 
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;
26 
27 #endif /* VHOST_BACKEND_H_ */
28