qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] virtio-fs: fix MSI-X nvectors calculation


From: Dr. David Alan Gilbert
Subject: Re: [PATCH] virtio-fs: fix MSI-X nvectors calculation
Date: Fri, 13 Dec 2019 10:55:26 +0000
User-agent: Mutt/1.13.0 (2019-11-30)

* Stefan Hajnoczi (address@hidden) wrote:
> The following MSI-X vectors are required:
>  * VIRTIO Configuration Change
>  * hiprio virtqueue
>  * requests virtqueues
> 
> Fix the calculation to reserve enough MSI-X vectors.  Otherwise guest
> drivers fall back to a sub-optional configuration where all virtqueues
> share a single vector.
> 
> This change does not break live migration compatibility since
> vhost-user-fs-pci devices are not migratable yet.
> 
> Reported-by: Vivek Goyal <address@hidden>
> Signed-off-by: Stefan Hajnoczi <address@hidden>

Queued for virtiofs

> ---
>  hw/virtio/vhost-user-fs-pci.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/hw/virtio/vhost-user-fs-pci.c b/hw/virtio/vhost-user-fs-pci.c
> index 933a3f265b..e3a649d4a6 100644
> --- a/hw/virtio/vhost-user-fs-pci.c
> +++ b/hw/virtio/vhost-user-fs-pci.c
> @@ -40,7 +40,8 @@ static void vhost_user_fs_pci_realize(VirtIOPCIProxy 
> *vpci_dev, Error **errp)
>      DeviceState *vdev = DEVICE(&dev->vdev);
>  
>      if (vpci_dev->nvectors == DEV_NVECTORS_UNSPECIFIED) {
> -        vpci_dev->nvectors = dev->vdev.conf.num_request_queues + 1;
> +        /* Also reserve config change and hiprio queue vectors */
> +        vpci_dev->nvectors = dev->vdev.conf.num_request_queues + 2;
>      }
>  
>      qdev_set_parent_bus(vdev, BUS(&vpci_dev->bus));
> -- 
> 2.23.0
> 
> 
--
Dr. David Alan Gilbert / address@hidden / Manchester, UK




reply via email to

[Prev in Thread] Current Thread [Next in Thread]