[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH for-5.0 28/31] block: Drop bdrv_format_default_perms()
From: |
Max Reitz |
Subject: |
[PATCH for-5.0 28/31] block: Drop bdrv_format_default_perms() |
Date: |
Wed, 27 Nov 2019 14:16:21 +0100 |
Signed-off-by: Max Reitz <address@hidden>
---
block.c | 19 -------------------
include/block/block_int.h | 11 -----------
2 files changed, 30 deletions(-)
diff --git a/block.c b/block.c
index b6c92ef283..3fcd56aaae 100644
--- a/block.c
+++ b/block.c
@@ -2294,25 +2294,6 @@ static void bdrv_default_perms_for_data(BlockDriverState
*bs, BdrvChild *c,
*nshared = shared;
}
-void bdrv_format_default_perms(BlockDriverState *bs, BdrvChild *c,
- const BdrvChildClass *child_class,
- BdrvChildRole role,
- BlockReopenQueue *reopen_queue,
- uint64_t perm, uint64_t shared,
- uint64_t *nperm, uint64_t *nshared)
-{
- if (child_class == &child_of_bds) {
- bdrv_default_perms(bs, c, child_class, role, reopen_queue,
- perm, shared, nperm, nshared);
- return;
- }
-
- assert(child_class == &child_file);
-
- bdrv_default_perms_for_metadata(bs, c, child_class, role, reopen_queue,
- perm, shared, nperm, nshared);
-}
-
void bdrv_default_perms(BlockDriverState *bs, BdrvChild *c,
const BdrvChildClass *child_class, BdrvChildRole role,
BlockReopenQueue *reopen_queue,
diff --git a/include/block/block_int.h b/include/block/block_int.h
index 7818734708..05e7a27318 100644
--- a/include/block/block_int.h
+++ b/include/block/block_int.h
@@ -1243,17 +1243,6 @@ int bdrv_child_try_set_perm(BdrvChild *c, uint64_t perm,
uint64_t shared,
*/
int bdrv_child_refresh_perms(BlockDriverState *bs, BdrvChild *c, Error **errp);
-/* Default implementation for BlockDriver.bdrv_child_perm() that can be used by
- * (non-raw) image formats: Like above for bs->backing, but for bs->file it
- * requires WRITE | RESIZE for read-write images, always requires
- * CONSISTENT_READ and doesn't share WRITE. */
-void bdrv_format_default_perms(BlockDriverState *bs, BdrvChild *c,
- const BdrvChildClass *child_class,
- BdrvChildRole child_role,
- BlockReopenQueue *reopen_queue,
- uint64_t perm, uint64_t shared,
- uint64_t *nperm, uint64_t *nshared);
-
bool bdrv_recurse_can_replace(BlockDriverState *bs,
BlockDriverState *to_replace);
--
2.23.0
- [PATCH for-5.0 17/31] raw-format: Split raw_read_options(), (continued)
- [PATCH for-5.0 17/31] raw-format: Split raw_read_options(), Max Reitz, 2019/11/27
- [PATCH for-5.0 19/31] block: Drop child_format, Max Reitz, 2019/11/27
- [PATCH for-5.0 20/31] block: Make backing files child_of_bds children, Max Reitz, 2019/11/27
- [PATCH for-5.0 21/31] block: Drop child_backing, Max Reitz, 2019/11/27
- [PATCH for-5.0 23/31] block: Make filter drivers use child_of_bds, Max Reitz, 2019/11/27
- [PATCH for-5.0 22/31] block: Make format drivers use child_of_bds, Max Reitz, 2019/11/27
- [PATCH for-5.0 24/31] block: Use child_of_bds in remaining places, Max Reitz, 2019/11/27
- [PATCH for-5.0 25/31] tests: Use child_of_bds instead of child_file, Max Reitz, 2019/11/27
- [PATCH for-5.0 27/31] block: Make bdrv_filter_default_perms() static, Max Reitz, 2019/11/27
- [PATCH for-5.0 26/31] block: Use bdrv_default_perms(), Max Reitz, 2019/11/27
- [PATCH for-5.0 28/31] block: Drop bdrv_format_default_perms(),
Max Reitz <=
- [PATCH for-5.0 31/31] block: Drop @child_class from bdrv_child_perm(), Max Reitz, 2019/11/27
- [PATCH for-5.0 30/31] block: Pass BdrvChildRole in remaining cases, Max Reitz, 2019/11/27
- [PATCH for-5.0 29/31] block: Drop child_file, Max Reitz, 2019/11/27
- [PATCH for-5.0 18/31] block: Switch child_format users to child_of_bds, Max Reitz, 2019/11/27