diff options
author | Nikunj A Dadhania <nikunj@linux.vnet.ibm.com> | 2016-02-10 14:35:06 +0530 |
---|---|---|
committer | Alexey Kardashevskiy <aik@ozlabs.ru> | 2016-02-11 12:44:27 +1100 |
commit | 409966d69b687ef1665d514ef0b43c971a4610c8 (patch) | |
tree | a6acac2d3fa120eb7e2512f7c15a5d1b1a3067ab /lib | |
parent | 6e4d62c2ebf9f2013dc59a3566f66f11adc4003b (diff) | |
download | SLOF-409966d69b687ef1665d514ef0b43c971a4610c8.zip SLOF-409966d69b687ef1665d514ef0b43c971a4610c8.tar.gz SLOF-409966d69b687ef1665d514ef0b43c971a4610c8.tar.bz2 |
virtio-scsi: use idx during initialization
Fix the initialization of the virtqueues. It was always initializing the
first virtqueue, while the objective is to init all the virtqueues.
Signed-off-by: Nikunj A Dadhania <nikunj@linux.vnet.ibm.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/libvirtio/virtio-scsi.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libvirtio/virtio-scsi.c b/lib/libvirtio/virtio-scsi.c index fd65a03..3128252 100644 --- a/lib/libvirtio/virtio-scsi.c +++ b/lib/libvirtio/virtio-scsi.c @@ -123,7 +123,7 @@ int virtioscsi_init(struct virtio_device *dev) break; virtio_vring_size(qsize); - vq_avail = virtio_get_vring_avail(dev, 0); + vq_avail = virtio_get_vring_avail(dev, idx); vq_avail->flags = VRING_AVAIL_F_NO_INTERRUPT; vq_avail->idx = 0; idx++; |