qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH] virtio: add the queue number check


From: Paolo Bonzini
Subject: Re: [PATCH] virtio: add the queue number check
Date: Fri, 3 Jan 2020 22:18:58 +0100



Il ven 3 gen 2020, 16:08 Yang Zhong <address@hidden> ha scritto:
  I also tried virtio-blk device like below:
  https://patchwork.kernel.org/cover/10873193/

  The virtio-blk can work with this changes, but vhost-user-blk device
  failed with this kernel patch.

  in vhost_virtqueue_start() function, below operation to check if the
  desc addr set by guest kernel. This will ignore the extra vqs.
    a = virtio_queue_get_desc_addr(vdev, idx);
    if (a == 0) {
        /* Queue might not be ready for start */
        return 0;
    }

  If guest kernel add min(cpu,num_vqs), do we need add same check in
  realize function of vhost-user-blk device?

No. If virtio-blk works, the bug is in vhost-user-blk; if virtio-blk needs no check in cpu count, vhost-user-blk also doesn't.

You need to check first if the bug is in QEMU or the vhost-user-blk server.

Paolo

reply via email to

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