Re: [Qemu-devel] [PATCH v4 10/11] dataplane: add virtio-blk data plane code

2012-11-30 Thread Stefan Hajnoczi
On Thu, Nov 29, 2012 at 4:47 PM, Paolo Bonzini pbonz...@redhat.com wrote: Stefan, perhaps you could replace the stop_notifier mechanism of event-poll.c with something similar to aio_notify/qemu_notify_event, and even remove event_poll_run in favor of event_poll (aka aio_wait...). And also

Re: [Qemu-devel] [PATCH v4 10/11] dataplane: add virtio-blk data plane code

2012-11-29 Thread Michael S. Tsirkin
On Thu, Nov 22, 2012 at 04:16:51PM +0100, Stefan Hajnoczi wrote: virtio-blk-data-plane is a subset implementation of virtio-blk. It only handles read, write, and flush requests. It does this using a dedicated thread that executes an epoll(2)-based event loop and processes I/O using Linux

Re: [Qemu-devel] [PATCH v4 10/11] dataplane: add virtio-blk data plane code

2012-11-29 Thread Michael S. Tsirkin
On Thu, Nov 22, 2012 at 04:16:51PM +0100, Stefan Hajnoczi wrote: virtio-blk-data-plane is a subset implementation of virtio-blk. It only handles read, write, and flush requests. It does this using a dedicated thread that executes an epoll(2)-based event loop and processes I/O using Linux

Re: [Qemu-devel] [PATCH v4 10/11] dataplane: add virtio-blk data plane code

2012-11-29 Thread Paolo Bonzini
+unsigned int num_reqs; +QemuMutex num_reqs_lock; OK the only reason this lock is needed is because you want to drain outside the thread. Won't it be better to queue process the drain request through the thread? You won't need any locks then. Draining is processed in the

Re: [Qemu-devel] [PATCH v4 10/11] dataplane: add virtio-blk data plane code

2012-11-29 Thread Michael S. Tsirkin
On Thu, Nov 29, 2012 at 10:21:31AM -0500, Paolo Bonzini wrote: +unsigned int num_reqs; +QemuMutex num_reqs_lock; OK the only reason this lock is needed is because you want to drain outside the thread. Won't it be better to queue process the drain request through the

Re: [Qemu-devel] [PATCH v4 10/11] dataplane: add virtio-blk data plane code

2012-11-29 Thread Paolo Bonzini
- Messaggio originale - Da: Michael S. Tsirkin m...@redhat.com A: Paolo Bonzini pbonz...@redhat.com Cc: qemu-devel@nongnu.org, Kevin Wolf kw...@redhat.com, Anthony Liguori aligu...@us.ibm.com, Blue Swirl blauwir...@gmail.com, k...@us.ibm.com, Asias He as...@redhat.com, Stefan

[Qemu-devel] [PATCH v4 10/11] dataplane: add virtio-blk data plane code

2012-11-22 Thread Stefan Hajnoczi
virtio-blk-data-plane is a subset implementation of virtio-blk. It only handles read, write, and flush requests. It does this using a dedicated thread that executes an epoll(2)-based event loop and processes I/O using Linux AIO. This approach performs very well but can be used for raw image