From 79a292e5ec767eea27a0cc456570ee028f4e3972 Mon Sep 17 00:00:00 2001 From: Kevin Wolf Date: Fri, 3 Feb 2023 16:21:58 +0100 Subject: block: Mark bdrv_co_eject/lock_medium() and callers GRAPH_RDLOCK This adds GRAPH_RDLOCK annotations to declare that callers of bdrv_co_eject() and bdrv_co_lock_medium() need to hold a reader lock for the graph. Signed-off-by: Emanuele Giuseppe Esposito Signed-off-by: Kevin Wolf Message-Id: <20230203152202.49054-20-kwolf@redhat.com> Reviewed-by: Emanuele Giuseppe Esposito Signed-off-by: Kevin Wolf --- block/filter-compress.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'block/filter-compress.c') diff --git a/block/filter-compress.c b/block/filter-compress.c index 0dd5606410..c7d50a67a7 100644 --- a/block/filter-compress.c +++ b/block/filter-compress.c @@ -114,14 +114,14 @@ static void compress_refresh_limits(BlockDriverState *bs, Error **errp) } -static void coroutine_fn +static void coroutine_fn GRAPH_RDLOCK compress_co_eject(BlockDriverState *bs, bool eject_flag) { bdrv_co_eject(bs->file->bs, eject_flag); } -static void coroutine_fn +static void coroutine_fn GRAPH_RDLOCK compress_co_lock_medium(BlockDriverState *bs, bool locked) { bdrv_co_lock_medium(bs->file->bs, locked); -- cgit v1.2.3