aboutsummaryrefslogtreecommitdiff
path: root/block.c
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2023-10-27 17:53:20 +0200
committerKevin Wolf <kwolf@redhat.com>2023-11-07 19:14:19 +0100
commitec82cc41a79ffa8b1a2dee76a420a34a59f117c6 (patch)
treeddf2688b003771da23cd81e3adf6af6699185af7 /block.c
parent79bb76272763c090f2b1dae9519c516257241cac (diff)
downloadqemu-ec82cc41a79ffa8b1a2dee76a420a34a59f117c6.zip
qemu-ec82cc41a79ffa8b1a2dee76a420a34a59f117c6.tar.gz
qemu-ec82cc41a79ffa8b1a2dee76a420a34a59f117c6.tar.bz2
block: Mark bdrv_filter_child() and callers GRAPH_RDLOCK
This adds GRAPH_RDLOCK annotations to declare that callers of bdrv_filter_child() need to hold a reader lock for the graph because it accesses bs->file/backing. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Message-ID: <20231027155333.420094-12-kwolf@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'block.c')
-rw-r--r--block.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/block.c b/block.c
index bb322df..499b147 100644
--- a/block.c
+++ b/block.c
@@ -8491,8 +8491,8 @@ BdrvChild *bdrv_primary_child(BlockDriverState *bs)
return found;
}
-static BlockDriverState *bdrv_do_skip_filters(BlockDriverState *bs,
- bool stop_on_explicit_filter)
+static BlockDriverState * GRAPH_RDLOCK
+bdrv_do_skip_filters(BlockDriverState *bs, bool stop_on_explicit_filter)
{
BdrvChild *c;