From 722f8c51d8af223751dfb1d02de40043e8ba067e Mon Sep 17 00:00:00 2001 From: Michael S. Tsirkin Date: Mon, 9 Dec 2019 11:46:13 -0500 Subject: virtio: add ability to delete vq through a pointer Devices tend to maintain vq pointers, allow deleting them trough a vq pointer. Signed-off-by: Michael S. Tsirkin Reviewed-by: David Hildenbrand Reviewed-by: David Hildenbrand --- include/hw/virtio/virtio.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/hw/virtio') diff --git a/include/hw/virtio/virtio.h b/include/hw/virtio/virtio.h index c32a815303..e18756d50d 100644 --- a/include/hw/virtio/virtio.h +++ b/include/hw/virtio/virtio.h @@ -183,6 +183,8 @@ VirtQueue *virtio_add_queue(VirtIODevice *vdev, int queue_size, void virtio_del_queue(VirtIODevice *vdev, int n); +void virtio_delete_queue(VirtQueue *vq); + void virtqueue_push(VirtQueue *vq, const VirtQueueElement *elem, unsigned int len); void virtqueue_flush(VirtQueue *vq, unsigned int count); -- cgit v1.2.3-55-g7522