diff options
author | Paolo Bonzini <pbonzini@redhat.com> | 2017-01-10 11:54:52 +0100 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2017-01-16 17:52:35 +0100 |
commit | d6da1e9eca939e8f9d41639be17c4bf5af7d5625 (patch) | |
tree | a97b13d93a53d6512b48c8483b75e2516f2c72c3 /include | |
parent | a0f80010b37afc18030d43f2b96cc1e0b7588b73 (diff) | |
download | qemu-d6da1e9eca939e8f9d41639be17c4bf5af7d5625.zip |
event_notifier: cleanups around event_notifier_set_handler
Remove the useless is_external argument. Since the iohandler
AioContext is never used for block devices, aio_disable_external
is never called on it. This lets us remove stubs/iohandler.c.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/qemu/event_notifier.h | 3 | ||||
-rw-r--r-- | include/qemu/main-loop.h | 15 |
2 files changed, 15 insertions, 3 deletions
diff --git a/include/qemu/event_notifier.h b/include/qemu/event_notifier.h index e326990db4..599c99f1a5 100644 --- a/include/qemu/event_notifier.h +++ b/include/qemu/event_notifier.h @@ -34,9 +34,6 @@ int event_notifier_init(EventNotifier *, int active); void event_notifier_cleanup(EventNotifier *); int event_notifier_set(EventNotifier *); int event_notifier_test_and_clear(EventNotifier *); -int event_notifier_set_handler(EventNotifier *, - bool is_external, - EventNotifierHandler *); #ifdef CONFIG_POSIX void event_notifier_init_fd(EventNotifier *, int fd); diff --git a/include/qemu/main-loop.h b/include/qemu/main-loop.h index a9d4f23cd9..d7e24af78d 100644 --- a/include/qemu/main-loop.h +++ b/include/qemu/main-loop.h @@ -203,6 +203,21 @@ void qemu_set_fd_handler(int fd, IOHandler *fd_write, void *opaque); + +/** + * event_notifier_set_handler: Register an EventNotifier with the main loop + * + * This function tells the main loop to wake up whenever the + * #EventNotifier was set. + * + * @e: The #EventNotifier to be observed. + * + * @handler: A level-triggered callback that is fired when @e + * has been set. @e is passed to it as a parameter. + */ +void event_notifier_set_handler(EventNotifier *e, + EventNotifierHandler *handler); + GSource *iohandler_get_g_source(void); AioContext *iohandler_get_aio_context(void); #ifdef CONFIG_POSIX |