diff mbox

[3/9] block: Make blk_all_next() public

Message ID 1499864249-26305-4-git-send-email-kwolf@redhat.com
State New
Headers show

Commit Message

Kevin Wolf July 12, 2017, 12:57 p.m. UTC
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
---
 block/block-backend.c          | 2 +-
 include/sysemu/block-backend.h | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

Comments

Eric Blake July 12, 2017, 3:25 p.m. UTC | #1
On 07/12/2017 07:57 AM, Kevin Wolf wrote:
> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
> ---
>  block/block-backend.c          | 2 +-
>  include/sysemu/block-backend.h | 1 +
>  2 files changed, 2 insertions(+), 1 deletion(-)

Reviewed-by: Eric Blake <eblake@redhat.com>

(although the commit message could mention WHY it is useful to be
public, because of a pending patch that will need it to do XYZ)
diff mbox

Patch

diff --git a/block/block-backend.c b/block/block-backend.c
index d60e53b..15072f8 100644
--- a/block/block-backend.c
+++ b/block/block-backend.c
@@ -342,7 +342,7 @@  void blk_unref(BlockBackend *blk)
  * Behaves similarly to blk_next() but iterates over all BlockBackends, even the
  * ones which are hidden (i.e. are not referenced by the monitor).
  */
-static BlockBackend *blk_all_next(BlockBackend *blk)
+BlockBackend *blk_all_next(BlockBackend *blk)
 {
     return blk ? QTAILQ_NEXT(blk, link)
                : QTAILQ_FIRST(&block_backends);
diff --git a/include/sysemu/block-backend.h b/include/sysemu/block-backend.h
index 80096f2..dfdd3b8 100644
--- a/include/sysemu/block-backend.h
+++ b/include/sysemu/block-backend.h
@@ -100,6 +100,7 @@  void blk_remove_all_bs(void);
 const char *blk_name(const BlockBackend *blk);
 BlockBackend *blk_by_name(const char *name);
 BlockBackend *blk_next(BlockBackend *blk);
+BlockBackend *blk_all_next(BlockBackend *blk);
 bool monitor_add_blk(BlockBackend *blk, const char *name, Error **errp);
 void monitor_remove_blk(BlockBackend *blk);