diff options
author | Stefan Hajnoczi <stefanha@redhat.com> | 2020-03-05 17:08:02 +0000 |
---|---|---|
committer | Stefan Hajnoczi <stefanha@redhat.com> | 2020-03-09 16:41:31 +0000 |
commit | 1f050a4690f62a1e7dabc4f44141e9f762c3769f (patch) | |
tree | 289c3970dfed15773b4a6cc234d2c580f28ef189 /MAINTAINERS | |
parent | 3aa221b382c9b36db1750ef5ed340b6566aacb8c (diff) |
aio-posix: extract ppoll(2) and epoll(7) fd monitoring
The ppoll(2) and epoll(7) file descriptor monitoring implementations are
mixed with the core util/aio-posix.c code. Before adding another
implementation for Linux io_uring, extract out the existing
ones so there is a clear interface and the core code is simpler.
The new interface is AioContext->fdmon_ops, a pointer to a FDMonOps
struct. See the patch for details.
Semantic changes:
1. ppoll(2) now reflects events from pollfds[] back into AioHandlers
while we're still on the clock for adaptive polling. This was
already happening for epoll(7), so if it's really an issue then we'll
need to fix both in the future.
2. epoll(7)'s fallback to ppoll(2) while external events are disabled
was broken when the number of fds exceeded the epoll(7) upgrade
threshold. I guess this code path simply wasn't tested and no one
noticed the bug. I didn't go out of my way to fix it but the correct
code is simpler than preserving the bug.
I also took some liberties in removing the unnecessary
AioContext->epoll_available (just check AioContext->epollfd != -1
instead) and AioContext->epoll_enabled (it's implicit if our
AioContext->fdmon_ops callbacks are being invoked) fields.
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Link: https://lore.kernel.org/r/20200305170806.1313245-4-stefanha@redhat.com
Message-Id: <20200305170806.1313245-4-stefanha@redhat.com>
Diffstat (limited to 'MAINTAINERS')
-rw-r--r-- | MAINTAINERS | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/MAINTAINERS b/MAINTAINERS index 36d0c6887a..66f46fa41a 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -1885,6 +1885,8 @@ L: qemu-block@nongnu.org S: Supported F: util/async.c F: util/aio-*.c +F: util/aio-*.h +F: util/fdmon-*.c F: block/io.c F: migration/block* F: include/block/aio.h |