mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-06 17:23:56 -06:00
block: Mark bdrv_amend_options() and callers GRAPH_RDLOCK
This adds GRAPH_RDLOCK annotations to declare that callers of bdrv_amend_options() need to hold a reader lock for the graph. This removes an assume_graph_lock() call in crypto's implementation. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Message-ID: <20230929145157.45443-14-kwolf@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
This commit is contained in:
parent
4026f1c4f3
commit
bd131d6705
4 changed files with 16 additions and 13 deletions
|
@ -828,7 +828,7 @@ block_crypto_amend_options_generic_luks(BlockDriverState *bs,
|
|||
errp);
|
||||
}
|
||||
|
||||
static int
|
||||
static int GRAPH_RDLOCK
|
||||
block_crypto_amend_options_luks(BlockDriverState *bs,
|
||||
QemuOpts *opts,
|
||||
BlockDriverAmendStatusCB *status_cb,
|
||||
|
@ -841,8 +841,6 @@ block_crypto_amend_options_luks(BlockDriverState *bs,
|
|||
QCryptoBlockAmendOptions *amend_options = NULL;
|
||||
int ret = -EINVAL;
|
||||
|
||||
assume_graph_lock(); /* FIXME */
|
||||
|
||||
assert(crypto);
|
||||
assert(crypto->block);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue