]> xenbits.xensource.com Git - qemu-upstream-unstable.git/commit
virtio: allow mapping up to max queue size
authorMichael S. Tsirkin <mst@redhat.com>
Mon, 12 May 2014 09:04:20 +0000 (12:04 +0300)
committerMichael Roth <mdroth@linux.vnet.ibm.com>
Mon, 21 Jul 2014 03:27:40 +0000 (22:27 -0500)
commit3ba1e617e7ae2b69a508a52b4f6cc301a9de95ce
tree1ade3f8707a9c2d8eab836a135914104b8962722
parent96e7f7a911077ac76c4b2ac1e31e0aeaa1fb2901
virtio: allow mapping up to max queue size

It's a loop from i < num_sg  and the array is VIRTQUEUE_MAX_SIZE - so
it's OK if the value read is VIRTQUEUE_MAX_SIZE.

Not a big problem in practice as people don't use
such big queues, but it's inelegant.

Reported-by: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
Cc: qemu-stable@nongnu.org
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
(cherry picked from commit 937251408051e0489f78e4db3c92e045b147b38b)
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
hw/virtio/virtio.c