diff options
author | Jason Wang <jasowang@redhat.com> | 2011-06-21 18:04:27 +0800 |
---|---|---|
committer | Michael S. Tsirkin <mst@redhat.com> | 2011-07-19 13:28:34 +0300 |
commit | f59281dafb832b161133743fcf3dc29051e6fdb8 (patch) | |
tree | 3eacc9fd60396174a94c8bd02326e930ff94351d /drivers/vhost/vhost.h | |
parent | 81fc70d86527a1450560709500ca5f52e661da1f (diff) | |
download | blackbird-op-linux-f59281dafb832b161133743fcf3dc29051e6fdb8.tar.gz blackbird-op-linux-f59281dafb832b161133743fcf3dc29051e6fdb8.zip |
vhost: init used ring after backend was set
Move the used ring initialization after backend was set. This
makes it possible to disable the backend and tweak the used ring,
then restart. This will also make it possible to log the used ring
write correctly.
Signed-off-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'drivers/vhost/vhost.h')
-rw-r--r-- | drivers/vhost/vhost.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/vhost/vhost.h b/drivers/vhost/vhost.h index 1544b782529b..14c9abf0d800 100644 --- a/drivers/vhost/vhost.h +++ b/drivers/vhost/vhost.h @@ -174,6 +174,7 @@ int vhost_get_vq_desc(struct vhost_dev *, struct vhost_virtqueue *, struct vhost_log *log, unsigned int *log_num); void vhost_discard_vq_desc(struct vhost_virtqueue *, int n); +int vhost_init_used(struct vhost_virtqueue *); int vhost_add_used(struct vhost_virtqueue *, unsigned int head, int len); int vhost_add_used_n(struct vhost_virtqueue *, struct vring_used_elem *heads, unsigned count); |