diff options
author | sochin.jiang <sochin.jiang@huawei.com> | 2017-06-26 19:04:24 +0800 |
---|---|---|
committer | Max Reitz <mreitz@redhat.com> | 2017-07-11 17:44:57 +0200 |
commit | 5ce6bfe255091d532ec4555d0ede816294cb1703 (patch) | |
tree | 9defcd4352cf25a90664d84dbfa7f9c8f132c7bf /block.c | |
parent | a9ed6a919360b998009508be03b056f2b7417ac5 (diff) | |
download | qemu-5ce6bfe255091d532ec4555d0ede816294cb1703.zip qemu-5ce6bfe255091d532ec4555d0ede816294cb1703.tar.gz qemu-5ce6bfe255091d532ec4555d0ede816294cb1703.tar.bz2 |
mirror: Fix inconsistent backing AioContext for after mirroring
mirror_complete opens the backing chain, which should have the same
AioContext as the top when using iothreads. Make the code guarantee
this, which fixes a failed assertion in bdrv_attach_child.
Signed-off-by: sochin.jiang <sochin.jiang@huawei.com>
Message-id: 1498475064-39816-1-git-send-email-sochin.jiang@huawei.com
[mreitz: Reworded commit message]
Signed-off-by: Max Reitz <mreitz@redhat.com>
Diffstat (limited to 'block.c')
-rw-r--r-- | block.c | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -2185,6 +2185,7 @@ int bdrv_open_backing_file(BlockDriverState *bs, QDict *parent_options, ret = -EINVAL; goto free_exit; } + bdrv_set_aio_context(backing_hd, bdrv_get_aio_context(bs)); /* Hook up the backing file link; drop our reference, bs owns the * backing_hd reference now */ |