From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:43676) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TRkbe-0006Rl-RN for qemu-devel@nongnu.org; Fri, 26 Oct 2012 10:10:00 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TRkba-0005eY-4C for qemu-devel@nongnu.org; Fri, 26 Oct 2012 10:09:50 -0400 Received: from mail-bk0-f45.google.com ([209.85.214.45]:61615) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TRkbZ-0005Sp-TY for qemu-devel@nongnu.org; Fri, 26 Oct 2012 10:09:46 -0400 Received: by mail-bk0-f45.google.com with SMTP id jf3so1090170bkc.4 for ; Fri, 26 Oct 2012 07:09:45 -0700 (PDT) Sender: Paolo Bonzini From: Paolo Bonzini Date: Fri, 26 Oct 2012 16:05:43 +0200 Message-Id: <1351260355-19802-14-git-send-email-pbonzini@redhat.com> In-Reply-To: <1351260355-19802-1-git-send-email-pbonzini@redhat.com> References: <1351260355-19802-1-git-send-email-pbonzini@redhat.com> Subject: [Qemu-devel] [PATCH 13/25] aio: call aio_notify after setting I/O handlers List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: aliguori@us.ibm.com, stefanha@redhat.com In the current code, this is done by qemu_set_fd_handler2, which is called by qemu_aio_set_fd_handler. We need to keep the same behavior even after removing the call to qemu_set_fd_handler2. Reviewed-by: Anthony Liguori Signed-off-by: Paolo Bonzini --- aio-posix.c | 2 ++ aio-win32.c | 2 ++ 2 file modificati, 4 inserzioni(+) diff --git a/aio-posix.c b/aio-posix.c index 65b2607..05cc84e 100644 --- a/aio-posix.c +++ b/aio-posix.c @@ -89,6 +89,8 @@ void aio_set_fd_handler(AioContext *ctx, node->pfd.events = (io_read ? G_IO_IN | G_IO_HUP : 0); node->pfd.events |= (io_write ? G_IO_OUT : 0); } + + aio_notify(ctx); } void aio_set_event_notifier(AioContext *ctx, diff --git a/aio-win32.c b/aio-win32.c index e460bd8..a84eb71 100644 --- a/aio-win32.c +++ b/aio-win32.c @@ -75,6 +75,8 @@ void aio_set_event_notifier(AioContext *ctx, node->io_notify = io_notify; node->io_flush = io_flush; } + + aio_notify(ctx); } bool aio_pending(AioContext *ctx) -- 1.7.12.1