Re: [Qemu-devel] [PATCH 5/9] virtio-blk: multiqueue batch notify

2016-05-27 Thread Stefan Hajnoczi
On Sat, May 21, 2016 at 06:02:52PM +0200, Paolo Bonzini wrote: > > > On 21/05/2016 01:40, Stefan Hajnoczi wrote: > > +while ((i = find_next_bit(s->batch_notify_vqs, nvqs, i)) < nvqs) { > > +VirtQueue *vq = virtio_get_queue(vdev, i); > > + > > +bitmap_clear(s->batch_notify_vqs,

Re: [Qemu-devel] [PATCH 5/9] virtio-blk: multiqueue batch notify

2016-05-23 Thread Fam Zheng
On Mon, 05/23 10:17, Paolo Bonzini wrote: > > > On 23/05/2016 04:43, Fam Zheng wrote: > > > The batch notification BH needs to know which virtqueues to notify when > > > multiqueue is enabled. Use a bitmap to track the virtqueues that with > > > pending notifications. > > > > This approach work

Re: [Qemu-devel] [PATCH 5/9] virtio-blk: multiqueue batch notify

2016-05-23 Thread Paolo Bonzini
On 23/05/2016 04:43, Fam Zheng wrote: > > The batch notification BH needs to know which virtqueues to notify when > > multiqueue is enabled. Use a bitmap to track the virtqueues that with > > pending notifications. > > This approach works great as long as VQs are in the same iothread. An > alte

Re: [Qemu-devel] [PATCH 5/9] virtio-blk: multiqueue batch notify

2016-05-22 Thread Fam Zheng
On Fri, 05/20 16:40, Stefan Hajnoczi wrote: > The batch notification BH needs to know which virtqueues to notify when > multiqueue is enabled. Use a bitmap to track the virtqueues that with > pending notifications. This approach works great as long as VQs are in the same iothread. An alternative

Re: [Qemu-devel] [PATCH 5/9] virtio-blk: multiqueue batch notify

2016-05-21 Thread Paolo Bonzini
On 21/05/2016 01:40, Stefan Hajnoczi wrote: > +while ((i = find_next_bit(s->batch_notify_vqs, nvqs, i)) < nvqs) { > +VirtQueue *vq = virtio_get_queue(vdev, i); > + > +bitmap_clear(s->batch_notify_vqs, i, 1); clear_bit? > +if (s->dataplane_started && !s->dataplane_dis

[Qemu-devel] [PATCH 5/9] virtio-blk: multiqueue batch notify

2016-05-20 Thread Stefan Hajnoczi
The batch notification BH needs to know which virtqueues to notify when multiqueue is enabled. Use a bitmap to track the virtqueues that with pending notifications. Signed-off-by: Stefan Hajnoczi --- hw/block/virtio-blk.c | 20 include/hw/virtio/virtio-blk.h | 1 +