qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH] virtio-pci: report an error when disable msix


From: Michael S. Tsirkin
Subject: Re: [Qemu-devel] [PATCH] virtio-pci: report an error when disable msix
Date: Thu, 22 May 2014 12:11:47 +0300

On Thu, May 22, 2014 at 05:02:17PM +0800, Amos Kong wrote:
> QEMU remains 4k memory for PCI BAR, each msix entry takes 16 bytes.
> If user assigns more than 128 vectors, msix resource isn't enough,
> so msix will be disabled.
> 
> This patch addes a note when fail to init exclusive bars for msix.
> 
>  qemu -device virtio-net-pci,netdev=h1,vectors=129,mq=on \
>       -netdev tap,id=h1,queues=8
> 
> Signed-off-by: Amos Kong <address@hidden>

OK I guess, but how about removing the limit instead?

> ---
>  hw/virtio/virtio-pci.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c
> index ce97514..ea5dcdf 100644
> --- a/hw/virtio/virtio-pci.c
> +++ b/hw/virtio/virtio-pci.c
> @@ -976,6 +976,8 @@ static void virtio_pci_device_plugged(DeviceState *d)
>  
>      if (proxy->nvectors &&
>          msix_init_exclusive_bar(&proxy->pci_dev, proxy->nvectors, 1)) {
> +        error_report("%s: unable to init exclusive bars for msix, disable 
> msix",
> +                     __func__);
>          proxy->nvectors = 0;
>      }
>  
> -- 
> 1.9.0



reply via email to

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