All of lore.kernel.org
 help / color / mirror / Atom feed
From: Cornelia Huck <cohuck@redhat.com>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: qemu-arm@nongnu.org, qemu-devel@nongnu.org,
	Eric Auger <eric.auger@redhat.com>,
	Sebastian Ott <sebott@redhat.com>
Subject: Re: [PATCH v2] arm/kvm: report registers we failed to set
Date: Thu, 11 Sep 2025 17:20:38 +0200	[thread overview]
Message-ID: <877by5f22h.fsf@redhat.com> (raw)
In-Reply-To: <CAFEAcA-_FgV69C6mKk5XiaQwj=LQD=C9ecjcm_gGuhEjYD3dyw@mail.gmail.com>

On Thu, Sep 11 2025, Peter Maydell <peter.maydell@linaro.org> wrote:

> On Tue, 2 Sept 2025 at 10:27, Cornelia Huck <cohuck@redhat.com> wrote:
>> +static gchar *kvm_print_register_name(uint64_t regidx)
>> +{
>> +        switch ((regidx & KVM_REG_ARM_COPROC_MASK)) {
>> +        case KVM_REG_ARM_CORE:
>> +            return g_strdup_printf("core reg %lx", regidx);
>> +        case KVM_REG_ARM_DEMUX:
>> +            return g_strdup_printf("demuxed reg %lx", regidx);
>
> You can't print a uint64_t with %lx. I suppose this code is
> only going to get compiled on a 64-bit host but we might
> someday want to move it so we can pretty-print registers
> elsewhere (e.g. in cpu_post_load() where we fail for
> "incoming migration stream has sysreg X but we don't know it").

OK, if we want to have this as some kind of generic function eventually,
it needs to become PRIx64.



      reply	other threads:[~2025-09-11 15:21 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-09-02  9:27 [PATCH v2] arm/kvm: report registers we failed to set Cornelia Huck
2025-09-02 15:49 ` Sebastian Ott
2025-09-11 13:03 ` Peter Maydell
2025-09-11 15:20   ` Cornelia Huck [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=877by5f22h.fsf@redhat.com \
    --to=cohuck@redhat.com \
    --cc=eric.auger@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-arm@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=sebott@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 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.