aboutsummaryrefslogtreecommitdiff
path: root/blockdev.c
diff options
context:
space:
mode:
authorMax Reitz <mreitz@redhat.com>2019-06-12 17:48:11 +0200
committerKevin Wolf <kwolf@redhat.com>2020-09-07 12:31:31 +0200
commit67acfd21885b70ae0cd11f12e34821be3d8b90bb (patch)
tree6f7762c221d6ff3f988e42bb93147ac9e59ae88e /blockdev.c
parentcb8503159a46f862303680816b1768bef78ac4e3 (diff)
downloadqemu-67acfd21885b70ae0cd11f12e34821be3d8b90bb.zip
qemu-67acfd21885b70ae0cd11f12e34821be3d8b90bb.tar.gz
qemu-67acfd21885b70ae0cd11f12e34821be3d8b90bb.tar.bz2
stream: Deal with filters
Because of the (not so recent anymore) changes that make the stream job independent of the base node and instead track the node above it, we have to split that "bottom" node into two cases: The bottom COW node, and the node directly above the base node (which may be an R/W filter or the bottom COW node). Signed-off-by: Max Reitz <mreitz@redhat.com>
Diffstat (limited to 'blockdev.c')
-rw-r--r--blockdev.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/blockdev.c b/blockdev.c
index 3848a9c..862aa1b 100644
--- a/blockdev.c
+++ b/blockdev.c
@@ -2528,7 +2528,9 @@ void qmp_block_stream(bool has_job_id, const char *job_id, const char *device,
}
/* Check for op blockers in the whole chain between bs and base */
- for (iter = bs; iter && iter != base_bs; iter = backing_bs(iter)) {
+ for (iter = bs; iter && iter != base_bs;
+ iter = bdrv_filter_or_cow_bs(iter))
+ {
if (bdrv_op_is_blocked(iter, BLOCK_OP_TYPE_STREAM, errp)) {
goto out;
}