On Wed, Mar 13, 2013 at 12:52:11PM -0500, Anthony Liguori wrote: > Paolo Bonzini <pbonz...@redhat.com> writes: > > > Il 13/03/2013 18:23, Anthony Liguori ha scritto: > >> I think the nesting is also a bit strange. > > > > Nesting's gone since we added coroutines. :) > > Okay, I owe AioContext a deeper look then.
We still have one level of nesting - the mainloop vs the AioContext aio_pool(). After all, we still have synchronous I/O operations like bdrv_read() where the file descriptors and BHs only execute in the AioContext aio_poll and other mainloop concepts are suspended (iohandlers, timers, slirp). We need to do something about mainloop vs AioContext. There should only be one interface to add a file descriptor, today we have iohandler and aio. Stefan