From: Laurent Vivier <laurent@vivier.eu>
To: "Philippe Mathieu-Daudé" <f4bug@amsat.org>, qemu-devel@nongnu.org
Cc: Laurent Vivier <lvivier@redhat.com>,
Thomas Huth <thuth@redhat.com>,
qemu-trivial@nongnu.org, Alexander Bulekov <alxndr@bu.edu>,
Bandan Das <bsd@redhat.com>,
Stefan Hajnoczi <stefanha@redhat.com>,
Paolo Bonzini <pbonzini@redhat.com>
Subject: Re: [PATCH v2] fuzz: Display hexadecimal value with '0x' prefix
Date: Sun, 13 Jun 2021 14:47:11 +0200 [thread overview]
Message-ID: <e947c86c-bd9b-6d91-d0f0-b8ce8833f295@vivier.eu> (raw)
In-Reply-To: <20210612195842.1595999-1-f4bug@amsat.org>
Le 12/06/2021 à 21:58, Philippe Mathieu-Daudé a écrit :
> Use memory_region_size() to get the MemoryRegion size,
> and display it with the '0x' prefix.
>
> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
> ---
> v2:
> - Use PRIx64 (lvivier)
> - Use memory_region_size()
> ---
> tests/qtest/fuzz/generic_fuzz.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/tests/qtest/fuzz/generic_fuzz.c b/tests/qtest/fuzz/generic_fuzz.c
> index cea7d4058e8..6c675227174 100644
> --- a/tests/qtest/fuzz/generic_fuzz.c
> +++ b/tests/qtest/fuzz/generic_fuzz.c
> @@ -841,9 +841,9 @@ static void generic_pre_fuzz(QTestState *s)
>
> g_hash_table_iter_init(&iter, fuzzable_memoryregions);
> while (g_hash_table_iter_next(&iter, (gpointer)&mr, NULL)) {
> - printf(" * %s (size %lx)\n",
> + printf(" * %s (size 0x%" PRIx64 ")\n",
> object_get_canonical_path_component(&(mr->parent_obj)),
> - (uint64_t)mr->size);
> + memory_region_size(mr));
> }
>
> if (!g_hash_table_size(fuzzable_memoryregions)) {
>
Reviewed-by: Laurent Vivier <laurent@vivier.eu>
prev parent reply other threads:[~2021-06-13 12:48 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-12 19:58 [PATCH v2] fuzz: Display hexadecimal value with '0x' prefix Philippe Mathieu-Daudé
2021-06-12 20:36 ` Richard Henderson
2021-06-13 2:23 ` Alexander Bulekov
2021-06-13 6:00 ` Thomas Huth
2021-06-13 12:47 ` Laurent Vivier [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=e947c86c-bd9b-6d91-d0f0-b8ce8833f295@vivier.eu \
--to=laurent@vivier.eu \
--cc=alxndr@bu.edu \
--cc=bsd@redhat.com \
--cc=f4bug@amsat.org \
--cc=lvivier@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-trivial@nongnu.org \
--cc=stefanha@redhat.com \
--cc=thuth@redhat.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).