[PATCH v2 1/2] server: enable POLLIN when asyncs waiting in readq

Dongwan Kim kdw6485 at gmail.com
Tue Dec 7 21:23:22 CST 2021


The situation is exactly what you said at last sentence.

The real situation in wine-client view is below :
GetQueuedCompletionStatus waits for 16 overlapped WSARecv.
After one IO Completion is processed, it does not wake up.


async_reselect() should be called after list_remove to
receive POLLIN event again.
async_waiting() only checks about the first entry in the queue.
Before calling list_remove(), async_waiting() returns false.

These stuff was done in async_destroy() on wine-6.7, and
I let the contents of async remained so that async_destroy()
handles it.

Apparently, as you said, test bot says there is a problem in this patch.

What about calling async_reselect() again right after calling list_remove()?

if (async->queue)
{
  list_remove( &async->queue_entry );
  async_reselect(async);
  async->fd = NULL;
  async->queue = NULL;
  release_object( async );
}

It does not cause assertion about handle_count and
make GetQueuedCompletionStatus wake up after IO completions.



More information about the wine-devel mailing list