mirror of
https://github.com/qemu/qemu.git
synced 2024-11-25 03:43:37 +08:00
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>
This commit is contained in:
parent
af7e916869
commit
37a81812f7
@ -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;
|
||||
|
Loading…
Reference in New Issue
Block a user