]> git.proxmox.com Git - mirror_qemu.git/commit
qemu-io-cmds: Use bdrv_coroutine_enter
authorFam Zheng <famz@redhat.com>
Mon, 10 Apr 2017 12:16:18 +0000 (20:16 +0800)
committerFam Zheng <famz@redhat.com>
Tue, 11 Apr 2017 12:07:15 +0000 (20:07 +0800)
commit324ec3e4f26e0a2a422478db4b9992f8aad3bde4
treed5afe9c6606b3f8dca60b28a61f51d3cafa1ee6e
parentaef4278c5a835c555ffe065f9e480190fd076675
qemu-io-cmds: Use bdrv_coroutine_enter

qemu_coroutine_create associates @co to qemu_aio_context but we poll
blk's context below. If the coroutine yields, it may never get resumed
again.

Use bdrv_coroutine_enter to make sure we are starting the I/O on the
right context.

Signed-off-by: Fam Zheng <famz@redhat.com>
Acked-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Kevin Wolf <kwolf@redhat.com>
qemu-io-cmds.c