From: Kevin Wolf <kwolf@redhat.com>
To: "Daniel P. Berrange" <dan@berrange.com>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH v2] Display logical disk size in 'info block' output
Date: Mon, 05 Sep 2011 14:44:53 +0200 [thread overview]
Message-ID: <4E64C445.5010402@redhat.com> (raw)
In-Reply-To: <1314981490-24200-1-git-send-email-dan@berrange.com>
Am 02.09.2011 18:38, schrieb Daniel P. Berrange:
> From: "Daniel P. Berrange" <dan@berrange.com>
>
> To aid in knowing whether a 'block_resize' was succesful, display
> the logical disk size in bytes, in the 'info block' output
>
> In v2:
> - Replace sectors with bytes
>
> Signed-off-by: Daniel P. Berrange <dan@berrange.com>
> ---
> block.c | 6 ++++--
> qmp-commands.hx | 1 +
> 2 files changed, 5 insertions(+), 2 deletions(-)
>
> diff --git a/block.c b/block.c
> index 03a21d8..03102ad 100644
> --- a/block.c
> +++ b/block.c
> @@ -1844,6 +1844,7 @@ static void bdrv_print_dict(QObject *obj, void *opaque)
>
> monitor_printf(mon, " file=");
> monitor_print_filename(mon, qdict_get_str(qdict, "file"));
> + monitor_printf(mon, " length=%" PRId64, qdict_get_int(qdict, "length"));
What about using get_human_readable_size() here? Or maybe we should
rather introduce an option that selects readable units or bytes for all
of the statistics? (The latter would be a separate patch, obviously)
Looks good to me otherwise, so if you don't like my suggestion I'll
merge it as it is.
Kevin
prev parent reply other threads:[~2011-09-05 12:42 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-09-02 16:38 [Qemu-devel] [PATCH v2] Display logical disk size in 'info block' output Daniel P. Berrange
2011-09-03 14:01 ` Stefan Hajnoczi
2011-09-05 12:44 ` Kevin Wolf [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4E64C445.5010402@redhat.com \
--to=kwolf@redhat.com \
--cc=dan@berrange.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.