diff options
author | Stefan Hajnoczi <stefanha@redhat.com> | 2016-12-01 19:26:49 +0000 |
---|---|---|
committer | Stefan Hajnoczi <stefanha@redhat.com> | 2017-01-03 16:38:50 +0000 |
commit | 684e508c23d28af8d6ed2c62738a0f60447c8274 (patch) | |
tree | acf9dd6f848c5419b756d30124f9727dafb3553d /aio-win32.c | |
parent | aff8fd18f1786fc5af259a9bc0077727222f51ca (diff) | |
download | qemu-684e508c23d28af8d6ed2c62738a0f60447c8274.zip qemu-684e508c23d28af8d6ed2c62738a0f60447c8274.tar.gz qemu-684e508c23d28af8d6ed2c62738a0f60447c8274.tar.bz2 |
aio: add .io_poll_begin/end() callbacks
The begin and end callbacks can be used to prepare for the polling loop
and clean up when polling stops. Note that they may only be called once
for multiple aio_poll() calls if polling continues to succeed. Once
polling fails the end callback is invoked before aio_poll() resumes file
descriptor monitoring.
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Message-id: 20161201192652.9509-11-stefanha@redhat.com
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'aio-win32.c')
-rw-r--r-- | aio-win32.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/aio-win32.c b/aio-win32.c index 0a6e91b..d0e40a8 100644 --- a/aio-win32.c +++ b/aio-win32.c @@ -102,6 +102,13 @@ void aio_set_fd_handler(AioContext *ctx, aio_notify(ctx); } +void aio_set_fd_poll(AioContext *ctx, int fd, + IOHandler *io_poll_begin, + IOHandler *io_poll_end) +{ + /* Not implemented */ +} + void aio_set_event_notifier(AioContext *ctx, EventNotifier *e, bool is_external, @@ -153,6 +160,14 @@ void aio_set_event_notifier(AioContext *ctx, aio_notify(ctx); } +void aio_set_event_notifier_poll(AioContext *ctx, + EventNotifier *notifier, + EventNotifierHandler *io_poll_begin, + EventNotifierHandler *io_poll_end) +{ + /* Not implemented */ +} + bool aio_prepare(AioContext *ctx) { static struct timeval tv0; |