qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2 05/33] block: Pass BdrvChildRole to bdrv_child_perm()


From: Eric Blake
Subject: Re: [PATCH v2 05/33] block: Pass BdrvChildRole to bdrv_child_perm()
Date: Wed, 5 Feb 2020 10:14:40 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.4.1

On 2/4/20 11:08 AM, Max Reitz wrote:
Signed-off-by: Max Reitz <address@hidden>

Sparse commit message - is the intent that this is no semantic change and just adding a parameter?

---
  block.c                     | 22 ++++++++++++----------
  block/backup-top.c          |  3 ++-
  block/blkdebug.c            |  5 +++--
  block/blklogwrites.c        |  9 +++++----
  block/commit.c              |  1 +
  block/copy-on-read.c        |  1 +
  block/mirror.c              |  1 +
  block/quorum.c              |  1 +
  block/replication.c         |  1 +
  block/vvfat.c               |  1 +
  include/block/block_int.h   |  5 ++++-
  tests/test-bdrv-drain.c     |  5 +++--
  tests/test-bdrv-graph-mod.c |  1 +
  13 files changed, 36 insertions(+), 20 deletions(-)

diff --git a/block.c b/block.c
index c576377650..7fa7830428 100644
--- a/block.c
+++ b/block.c
@@ -1764,12 +1764,12 @@ bool bdrv_is_writable(BlockDriverState *bs)
static void bdrv_child_perm(BlockDriverState *bs, BlockDriverState *child_bs,
                              BdrvChild *c, const BdrvChildClass *child_class,
-                            BlockReopenQueue *reopen_queue,
+                            BdrvChildRole role, BlockReopenQueue *reopen_queue,

Again, using an enum name where a bitmask of non-enum values is self-documenting, but somewhat abusive of C's loose type system. Is an unsigned int any better?

Looks mechanical enough. I'd like a better commit message, but:
Reviewed-by: Eric Blake <address@hidden>

--
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3226
Virtualization:  qemu.org | libvirt.org




reply via email to

[Prev in Thread] Current Thread [Next in Thread]