aboutsummaryrefslogtreecommitdiff
path: root/block/stream.c
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2023-10-27 17:53:21 +0200
committerKevin Wolf <kwolf@redhat.com>2023-11-07 19:14:19 +0100
commit78a9c76eefae877e63591728234604310c51d88f (patch)
tree08679e5fddc04ef8224686142754b16dc24a4038 /block/stream.c
parentec82cc41a79ffa8b1a2dee76a420a34a59f117c6 (diff)
downloadqemu-78a9c76eefae877e63591728234604310c51d88f.zip
qemu-78a9c76eefae877e63591728234604310c51d88f.tar.gz
qemu-78a9c76eefae877e63591728234604310c51d88f.tar.bz2
block: Mark bdrv_cow_child() and callers GRAPH_RDLOCK
This adds GRAPH_RDLOCK annotations to declare that callers of bdrv_cow_child() need to hold a reader lock for the graph because it accesses bs->backing. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Message-ID: <20231027155333.420094-13-kwolf@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'block/stream.c')
-rw-r--r--block/stream.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/block/stream.c b/block/stream.c
index c32c983..3f5d773 100644
--- a/block/stream.c
+++ b/block/stream.c
@@ -90,7 +90,7 @@ static int stream_prepare(Job *job)
unfiltered_base = bdrv_skip_filters(base);
bdrv_graph_rdunlock_main_loop();
- if (bdrv_cow_child(unfiltered_bs)) {
+ if (unfiltered_bs_cow) {
const char *base_id = NULL, *base_fmt = NULL;
if (unfiltered_base) {
base_id = s->backing_file_str ?: unfiltered_base->filename;