[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 20/64] block: bdrv_set_backing_hd() is about bs->backing
From: |
Kevin Wolf |
Subject: |
[PULL 20/64] block: bdrv_set_backing_hd() is about bs->backing |
Date: |
Mon, 7 Sep 2020 13:08:52 +0200 |
From: Max Reitz <mreitz@redhat.com>
bdrv_set_backing_hd() is a function that explicitly cares about the
bs->backing child. Highlight that in its description and use
child_bs(bs->backing) instead of backing_bs(bs) to make it more obvious.
Signed-off-by: Max Reitz <mreitz@redhat.com>
Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Reviewed-by: Andrey Shinkevich <andrey.shinkevich@virtuozzo.com>
Reviewed-by: Kevin Wolf <kwolf@redhat.com>
---
block.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/block.c b/block.c
index 656baa521e..e8d09d46ec 100644
--- a/block.c
+++ b/block.c
@@ -2863,7 +2863,7 @@ static BdrvChildRole bdrv_backing_role(BlockDriverState
*bs)
}
/*
- * Sets the backing file link of a BDS. A new reference is created; callers
+ * Sets the bs->backing link of a BDS. A new reference is created; callers
* which don't need their own reference any more must call bdrv_unref().
*/
void bdrv_set_backing_hd(BlockDriverState *bs, BlockDriverState *backing_hd,
@@ -2872,7 +2872,7 @@ void bdrv_set_backing_hd(BlockDriverState *bs,
BlockDriverState *backing_hd,
bool update_inherits_from = bdrv_chain_contains(bs, backing_hd) &&
bdrv_inherits_from_recursive(backing_hd, bs);
- if (bdrv_is_backing_chain_frozen(bs, backing_bs(bs), errp)) {
+ if (bdrv_is_backing_chain_frozen(bs, child_bs(bs->backing), errp)) {
return;
}
--
2.25.4
- [PULL 11/64] block/nvme: Replace qemu_try_blockalign(bs) by qemu_try_memalign(pg_sz), (continued)
- [PULL 11/64] block/nvme: Replace qemu_try_blockalign(bs) by qemu_try_memalign(pg_sz), Kevin Wolf, 2020/09/07
- [PULL 12/64] block/nvme: Simplify nvme_init_queue() arguments, Kevin Wolf, 2020/09/07
- [PULL 13/64] block/nvme: Replace BDRV_POLL_WHILE by AIO_WAIT_WHILE, Kevin Wolf, 2020/09/07
- [PULL 08/64] block/nvme: Rename local variable, Kevin Wolf, 2020/09/07
- [PULL 14/64] block/nvme: Simplify nvme_create_queue_pair() arguments, Kevin Wolf, 2020/09/07
- [PULL 15/64] block/nvme: Extract nvme_poll_queue(), Kevin Wolf, 2020/09/07
- [PULL 17/64] block: Add child access functions, Kevin Wolf, 2020/09/07
- [PULL 18/64] block: Add chain helper functions, Kevin Wolf, 2020/09/07
- [PULL 19/64] block: bdrv_cow_child() for bdrv_has_zero_init(), Kevin Wolf, 2020/09/07
- [PULL 16/64] block/nvme: Use an array of EventNotifier, Kevin Wolf, 2020/09/07
- [PULL 20/64] block: bdrv_set_backing_hd() is about bs->backing,
Kevin Wolf <=
- [PULL 21/64] block: Include filters when freezing backing chain, Kevin Wolf, 2020/09/07
- [PULL 23/64] block: Add bdrv_supports_compressed_writes(), Kevin Wolf, 2020/09/07
- [PULL 24/64] throttle: Support compressed writes, Kevin Wolf, 2020/09/07
- [PULL 26/64] block: Use bdrv_filter_(bs|child) where obvious, Kevin Wolf, 2020/09/07
- [PULL 22/64] block: Drop bdrv_is_encrypted(), Kevin Wolf, 2020/09/07
- [PULL 27/64] block: Use CAFs in block status functions, Kevin Wolf, 2020/09/07
- [PULL 25/64] copy-on-read: Support compressed writes, Kevin Wolf, 2020/09/07
- [PULL 28/64] stream: Deal with filters, Kevin Wolf, 2020/09/07
- [PULL 30/64] block: Use bdrv_cow_child() in bdrv_co_truncate(), Kevin Wolf, 2020/09/07
- [PULL 31/64] block: Re-evaluate backing file handling in reopen, Kevin Wolf, 2020/09/07