diff options
author | Feng Liu <feliu@nvidia.com> | 2023-12-19 10:32:40 +0100 |
---|---|---|
committer | Alex Williamson <alex.williamson@redhat.com> | 2023-12-19 19:51:31 +0100 |
commit | fd27ef6b44bec26915c5b2b22c13856d9f0ba17a (patch) | |
tree | e9823713c0bf880a4dbf580f4eaaca0d839fe300 /drivers/virtio/virtio_pci_common.c | |
parent | virtio: Define feature bit for administration virtqueue (diff) | |
download | linux-fd27ef6b44bec26915c5b2b22c13856d9f0ba17a.tar.xz linux-fd27ef6b44bec26915c5b2b22c13856d9f0ba17a.zip |
virtio-pci: Introduce admin virtqueue
Introduce support for the admin virtqueue. By negotiating
VIRTIO_F_ADMIN_VQ feature, driver detects capability and creates one
administration virtqueue. Administration virtqueue implementation in
virtio pci generic layer, enables multiple types of upper layer
drivers such as vfio, net, blk to utilize it.
Signed-off-by: Feng Liu <feliu@nvidia.com>
Reviewed-by: Parav Pandit <parav@nvidia.com>
Reviewed-by: Jiri Pirko <jiri@nvidia.com>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Yishai Hadas <yishaih@nvidia.com>
Link: https://lore.kernel.org/r/20231219093247.170936-3-yishaih@nvidia.com
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Diffstat (limited to 'drivers/virtio/virtio_pci_common.c')
-rw-r--r-- | drivers/virtio/virtio_pci_common.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/virtio/virtio_pci_common.c b/drivers/virtio/virtio_pci_common.c index 7a5593997e0e..fafd13d0e4d4 100644 --- a/drivers/virtio/virtio_pci_common.c +++ b/drivers/virtio/virtio_pci_common.c @@ -236,6 +236,9 @@ void vp_del_vqs(struct virtio_device *vdev) int i; list_for_each_entry_safe(vq, n, &vdev->vqs, list) { + if (vp_dev->is_avq(vdev, vq->index)) + continue; + if (vp_dev->per_vq_vectors) { int v = vp_dev->vqs[vq->index]->msix_vector; |