qemu-block
[Top][All Lists]
Advanced

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

Re: [PATCH v2 05/10] block: Convert bdrv_query_block_graph_info to corou


From: Hanna Czenczek
Subject: Re: [PATCH v2 05/10] block: Convert bdrv_query_block_graph_info to coroutine
Date: Mon, 6 Nov 2023 15:52:34 +0100
User-agent: Mozilla Thunderbird

On 09.06.23 22:19, Fabiano Rosas wrote:
We're converting callers of bdrv_get_allocated_file_size() to run in
coroutines because that function will be made asynchronous when called
(indirectly) from the QMP dispatcher.

This function is a candidate because it calls bdrv_do_query_node_info(),
which in turn calls bdrv_get_allocated_file_size().

All the functions called from bdrv_do_query_node_info() onwards are
coroutine-safe, either have a coroutine version themselves[1] or are
mostly simple code/string manipulation[2].

1) bdrv_getlength(), bdrv_get_allocated_file_size(), bdrv_get_info(),
    bdrv_get_specific_info();

2) bdrv_refresh_filename(), bdrv_get_format_name(),
    bdrv_get_full_backing_filename(), bdrv_query_snapshot_info_list();

Signed-off-by: Fabiano Rosas <farosas@suse.de>
---
  block/qapi.c         | 12 +++++++-----
  include/block/qapi.h |  6 +++++-
  qemu-img.c           |  2 --
  3 files changed, 12 insertions(+), 8 deletions(-)

Reviewed-by: Hanna Czenczek <hreitz@redhat.com>




reply via email to

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