tools/virtio: initialize spinlocks in vring_test.c
authorRicardo Cañuelo <ricardo.canuelo@collabora.com>
Wed, 12 Oct 2022 06:29:49 +0000 (08:29 +0200)
committerMichael S. Tsirkin <mst@redhat.com>
Wed, 28 Dec 2022 10:09:47 +0000 (05:09 -0500)
commitc262f75cb6bb5a63828e72ce3b8fe808e5029479
treeb9f55760064cc9da8007bae42796b3ec8f5a6b47
parentb9e05399d9273c8c066e73db1e6e85364003030c
tools/virtio: initialize spinlocks in vring_test.c

The virtio_device vqs_list spinlocks must be initialized before use to
prevent functions that manipulate the device virtualqueues, such as
vring_new_virtqueue(), from blocking indefinitely.

Signed-off-by: Ricardo Cañuelo <ricardo.canuelo@collabora.com>
Message-Id: <20221012062949.1526176-1-ricardo.canuelo@collabora.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Reviewed-by: Xuan Zhuo <xuanzhuo@linux.alibaba.com>
tools/virtio/vringh_test.c