On Sun, Jul 21, 2013 at 5:55 PM, Alex Bligh <a...@alex.org.uk> wrote: > > > --On 21 July 2013 16:43:03 +0800 Liu Ping Fan <qemul...@gmail.com> wrote: > >> diff --git a/aio-posix.c b/aio-posix.c >> index b68eccd..29c2769 100644 >> --- a/aio-posix.c >> +++ b/aio-posix.c >> @@ -191,6 +191,8 @@ bool aio_poll(AioContext *ctx, bool blocking) >> progress = true; >> } >> >> + qemu_run_all_timers(); >> + >> if (progress && !blocking) { >> return true; >> } > > > I am told (by Stefan H) this approach is unsafe as existing timers may > not expect to be run within aio_poll. > Have not figure out the reason, could you elaborate ?
Thanks > Also, I suspect you need to change the value of progress if timers > run so bdrv draining terminates properly. > Yes, you are right > -- > Alex Bligh