diff options
author | Stefan Hajnoczi <stefanha@redhat.com> | 2016-12-01 19:26:41 +0000 |
---|---|---|
committer | Stefan Hajnoczi <stefanha@redhat.com> | 2017-01-03 16:38:48 +0000 |
commit | f6a51c84cdc97e0178aab7690788d3891d2fcf0a (patch) | |
tree | a3006871b448d1041d7a2716895070f1bb6afa17 /aio-posix.c | |
parent | 721671ade77f4046b45893fbb7864ca84b9504cd (diff) |
aio: add AioPollFn and io_poll() interface
The new AioPollFn io_poll() argument to aio_set_fd_handler() and
aio_set_event_handler() is used in the next patch.
Keep this code change separate due to the number of files it touches.
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Message-id: 20161201192652.9509-3-stefanha@redhat.com
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'aio-posix.c')
-rw-r--r-- | aio-posix.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/aio-posix.c b/aio-posix.c index 4ac2346370..feab8e8a00 100644 --- a/aio-posix.c +++ b/aio-posix.c @@ -200,6 +200,7 @@ void aio_set_fd_handler(AioContext *ctx, bool is_external, IOHandler *io_read, IOHandler *io_write, + AioPollFn *io_poll, void *opaque) { AioHandler *node; @@ -258,10 +259,11 @@ void aio_set_fd_handler(AioContext *ctx, void aio_set_event_notifier(AioContext *ctx, EventNotifier *notifier, bool is_external, - EventNotifierHandler *io_read) + EventNotifierHandler *io_read, + AioPollFn *io_poll) { - aio_set_fd_handler(ctx, event_notifier_get_fd(notifier), - is_external, (IOHandler *)io_read, NULL, notifier); + aio_set_fd_handler(ctx, event_notifier_get_fd(notifier), is_external, + (IOHandler *)io_read, NULL, io_poll, notifier); } bool aio_prepare(AioContext *ctx) |