vhost-net: save & restore vring enable state
commitbfc6cf31ce12649b32dae0430fcbdb456fe6faf8
authorMarc-André Lureau <marcandre.lureau@redhat.com>
Mon, 6 Jun 2016 16:45:06 +0000 (6 18:45 +0200)
committerMichael S. Tsirkin <mst@redhat.com>
Fri, 17 Jun 2016 00:28:03 +0000 (17 03:28 +0300)
tree813fa0191e598c7acd134fac9095c486d5454e5e
parenta463215b087c41d7ca94e51aa347cde523831873
vhost-net: save & restore vring enable state

A driver may change the vring enable state at run time but vhost-user
backend may not be present (a contrived example is when the backend is
disconnected and the device is reconfigured after driver rebinding)

Restore the vring state when the vhost-user backend is started, so it
can process the ring.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Tested-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
Reviewed-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
Reviewed-by: Victor Kaplansky <victork@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
hw/net/vhost_net.c
include/net/net.h