From 37a81812f7b8367422a039eb09d915df543983ee Mon Sep 17 00:00:00 2001 From: Fam Zheng Date: Fri, 3 Aug 2018 14:39:17 +0800 Subject: aio-posix: Improve comment around marking node deleted The counter is for qemu_lockcnt_inc/dec sections (read side), qemu_lockcnt_lock/unlock is for the write side. Suggested-by: Paolo Bonzini Signed-off-by: Fam Zheng Message-Id: <20180803063917.30292-1-famz@redhat.com> Signed-off-by: Fam Zheng --- util/aio-posix.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'util') diff --git a/util/aio-posix.c b/util/aio-posix.c index b5c609b..131ba6b 100644 --- a/util/aio-posix.c +++ b/util/aio-posix.c @@ -232,7 +232,7 @@ void aio_set_fd_handler(AioContext *ctx, g_source_remove_poll(&ctx->source, &node->pfd); } - /* If the lock is held, just mark the node as deleted */ + /* If a read is in progress, just mark the node as deleted */ if (qemu_lockcnt_count(&ctx->list_lock)) { node->deleted = 1; node->pfd.revents = 0; -- cgit v1.1