diff options
author | Fam Zheng <famz@redhat.com> | 2018-08-03 14:39:17 +0800 |
---|---|---|
committer | Fam Zheng <famz@redhat.com> | 2018-08-15 10:12:35 +0800 |
commit | 37a81812f7b8367422a039eb09d915df543983ee (patch) | |
tree | c3c0097f412a618ca05fbcec062920f113f03860 /util/aio-posix.c | |
parent | af7e916869fc9aab5ba0511783417f1bc3f6df84 (diff) | |
download | qemu-37a81812f7b8367422a039eb09d915df543983ee.zip qemu-37a81812f7b8367422a039eb09d915df543983ee.tar.gz qemu-37a81812f7b8367422a039eb09d915df543983ee.tar.bz2 |
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 <pbonzini@redhat.com>
Signed-off-by: Fam Zheng <famz@redhat.com>
Message-Id: <20180803063917.30292-1-famz@redhat.com>
Signed-off-by: Fam Zheng <famz@redhat.com>
Diffstat (limited to 'util/aio-posix.c')
-rw-r--r-- | util/aio-posix.c | 2 |
1 files changed, 1 insertions, 1 deletions
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; |