|
|
357786 |
From 8c5d6c7bdc1cd5557503764ff8187d39bed3cbe1 Mon Sep 17 00:00:00 2001
|
|
|
357786 |
From: Fam Zheng <famz@redhat.com>
|
|
|
357786 |
Date: Fri, 17 Aug 2018 03:08:35 +0200
|
|
|
357786 |
Subject: [PATCH 4/5] aio-posix: Don't count ctx->notifier as progress when
|
|
|
357786 |
polling
|
|
|
357786 |
|
|
|
357786 |
RH-Author: Fam Zheng <famz@redhat.com>
|
|
|
357786 |
Message-id: <20180817030836.20581-2-famz@redhat.com>
|
|
|
357786 |
Patchwork-id: 81861
|
|
|
357786 |
O-Subject: [RHEL-7.6 qemu-kvm-rhev PATCH 1/2] aio-posix: Don't count ctx->notifier as progress when polling
|
|
|
357786 |
Bugzilla: 1562750
|
|
|
357786 |
RH-Acked-by: Paolo Bonzini <pbonzini@redhat.com>
|
|
|
357786 |
RH-Acked-by: Thomas Huth <thuth@redhat.com>
|
|
|
357786 |
RH-Acked-by: Laszlo Ersek <lersek@redhat.com>
|
|
|
357786 |
|
|
|
357786 |
The same logic exists in fd polling. This change is especially important
|
|
|
357786 |
to avoid busy loop once we limit aio_notify_accept() to blocking
|
|
|
357786 |
aio_poll().
|
|
|
357786 |
|
|
|
357786 |
Cc: qemu-stable@nongnu.org
|
|
|
357786 |
Signed-off-by: Fam Zheng <famz@redhat.com>
|
|
|
357786 |
Message-Id: <20180809132259.18402-2-famz@redhat.com>
|
|
|
357786 |
Signed-off-by: Fam Zheng <famz@redhat.com>
|
|
|
357786 |
(cherry picked from commit 70232b5253a3c4e03ed1ac47ef9246a8ac66c6fa)
|
|
|
357786 |
Signed-off-by: Fam Zheng <famz@redhat.com>
|
|
|
357786 |
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
|
|
|
357786 |
---
|
|
|
357786 |
util/aio-posix.c | 3 ++-
|
|
|
357786 |
1 file changed, 2 insertions(+), 1 deletion(-)
|
|
|
357786 |
|
|
|
357786 |
diff --git a/util/aio-posix.c b/util/aio-posix.c
|
|
|
357786 |
index d8f0cb4..f650c7c 100644
|
|
|
357786 |
--- a/util/aio-posix.c
|
|
|
357786 |
+++ b/util/aio-posix.c
|
|
|
357786 |
@@ -494,7 +494,8 @@ static bool run_poll_handlers_once(AioContext *ctx)
|
|
|
357786 |
QLIST_FOREACH_RCU(node, &ctx->aio_handlers, node) {
|
|
|
357786 |
if (!node->deleted && node->io_poll &&
|
|
|
357786 |
aio_node_check(ctx, node->is_external) &&
|
|
|
357786 |
- node->io_poll(node->opaque)) {
|
|
|
357786 |
+ node->io_poll(node->opaque) &&
|
|
|
357786 |
+ node->opaque != &ctx->notifier) {
|
|
|
357786 |
progress = true;
|
|
|
357786 |
}
|
|
|
357786 |
|
|
|
357786 |
--
|
|
|
357786 |
1.8.3.1
|
|
|
357786 |
|