Re: [PATCH] aio-posix: fix spurious ->poll_ready() callbacks in main loop

2022-03-01 Thread Stefan Hajnoczi
On Wed, Feb 23, 2022 at 03:57:03PM +, Stefan Hajnoczi wrote: > When ->poll() succeeds the AioHandler is placed on the ready list with > revents set to the magic value 0. This magic value causes > aio_dispatch_handler() to invoke ->poll_ready() instead of ->io_read() > for G_IO_IN or ->io_write(

Re: [PATCH] aio-posix: fix spurious ->poll_ready() callbacks in main loop

2022-02-24 Thread Jason Wang
在 2022/2/23 下午11:57, Stefan Hajnoczi 写道: When ->poll() succeeds the AioHandler is placed on the ready list with revents set to the magic value 0. This magic value causes aio_dispatch_handler() to invoke ->poll_ready() instead of ->io_read() for G_IO_IN or ->io_write() for G_IO_OUT. This magic

[PATCH] aio-posix: fix spurious ->poll_ready() callbacks in main loop

2022-02-23 Thread Stefan Hajnoczi
When ->poll() succeeds the AioHandler is placed on the ready list with revents set to the magic value 0. This magic value causes aio_dispatch_handler() to invoke ->poll_ready() instead of ->io_read() for G_IO_IN or ->io_write() for G_IO_OUT. This magic value 0 hack works for the IOThread where Aio