summaryrefslogtreecommitdiffstats
path: root/include/net/vhost_net.h
diff options
context:
space:
mode:
authorNikolay Nikolaev2014-05-27 14:05:49 +0200
committerMichael S. Tsirkin2014-06-19 15:41:56 +0200
commit1a1bfac9ee13d76a4b257431cc4193c8a42efa19 (patch)
tree47c0d93e3931a6992f5835c5d292533e931789bf /include/net/vhost_net.h
parentAdd vhost_ops to vhost_dev struct and replace all relevant ioctls (diff)
downloadqemu-1a1bfac9ee13d76a4b257431cc4193c8a42efa19.tar.gz
qemu-1a1bfac9ee13d76a4b257431cc4193c8a42efa19.tar.xz
qemu-1a1bfac9ee13d76a4b257431cc4193c8a42efa19.zip
Add vhost-backend and VhostBackendType
Use vhost_set_backend_type to initialise a proper vhost_ops structure. In vhost_net_init and vhost_net_start_one call conditionally TAP related initialisation depending on the vhost backend type. Signed-off-by: Antonios Motakis <a.motakis@virtualopensystems.com> Signed-off-by: Nikolay Nikolaev <n.nikolaev@virtualopensystems.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'include/net/vhost_net.h')
-rw-r--r--include/net/vhost_net.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/net/vhost_net.h b/include/net/vhost_net.h
index 2067ee2298..b1c18a3f3b 100644
--- a/include/net/vhost_net.h
+++ b/include/net/vhost_net.h
@@ -2,11 +2,13 @@
#define VHOST_NET_H
#include "net/net.h"
+#include "hw/virtio/vhost-backend.h"
struct vhost_net;
typedef struct vhost_net VHostNetState;
typedef struct VhostNetOptions {
+ VhostBackendType backend_type;
NetClientState *net_backend;
void *opaque;
bool force;