All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: qemu-devel <qemu-devel@nongnu.org>
Subject: Re: Odd square bracket encoding in QOM names
Date: Tue, 30 Nov 2021 18:44:10 +0000	[thread overview]
Message-ID: <cac74117-82d9-63c1-e107-39af293980f9@ilande.co.uk> (raw)
In-Reply-To: <CAFEAcA-4sA+xUkzxoFyXiw=LmEZkJRkBhCx+2YZ7x30Omr+new@mail.gmail.com>

On 30/11/2021 16:41, Peter Maydell wrote:

> On Tue, 30 Nov 2021 at 08:36, Mark Cave-Ayland
> <mark.cave-ayland@ilande.co.uk> wrote:
>> Has there been a recent change as to how square brackets are encoded within QOM
>> names? I noticed that the output has changed here in the "info qom-tree" output in
>> qemu-system-m68k for the q800 machine.
>>
>> The q800 machine has a set of 256 memory region aliases that used to appear in the
>> "info qom-tree" output as:
>>
>>       /mac_m68k.io[100] (memory-region)
>>       /mac_m68k.io[101] (memory-region)
>>       /mac_m68k.io[102] (memory-region)
>>
>> but they now appear as:
>>
>>       /mac_m68k.io\x5b100\x5d[0] (memory-region)
>>       /mac_m68k.io\x5b101\x5d[0] (memory-region)
>>       /mac_m68k.io\x5b102\x5d[0] (memory-region)
> 
> I looked at info qom-tree for an Arm machine, and the [..] seem to be
> OK there. I tried to test with q800 but got stuck on finding a
> command line to get it to run. Do you have repro instructions?

A couple of tests this evening and I think I must have misremembered this - I tried a 
couple of older versions of my various q800 branches (one within the 6.0 dev cycle 
and another within 6.1) and both escape the QOM object name in "info qom-tree" the 
same way as above.

Easiest way to see this is to grab Finn's kernel from issue #611 like this:

$ wget 
https://gitlab.com/qemu-project/qemu/uploads/dead759323116fb22cf0f03b8cdbe15a/vmlinux-5.14-multi.xz
$ unxz vmlinux-5.14-multi.xz

And then start QEMU with this command line:

$ ./qemu-system-m68k -M q800 -kernel vmlinux-5.14-multi -monitor stdio -S

Obviously the cause is the use of square brackets within the memory region name as 
per https://gitlab.com/qemu-project/qemu/-/blob/master/hw/m68k/q800.c#L411, so given 
the escaping has been like this for some time then I guess everything is working as 
intended, and sorry for the noise.


ATB,

Mark.


      reply	other threads:[~2021-11-30 18:46 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-30  8:35 Odd square bracket encoding in QOM names Mark Cave-Ayland
2021-11-30  9:41 ` Michal Prívozník
2021-12-01 13:58   ` Philippe Mathieu-Daudé
2021-11-30 16:41 ` Peter Maydell
2021-11-30 18:44   ` Mark Cave-Ayland [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=cac74117-82d9-63c1-e107-39af293980f9@ilande.co.uk \
    --to=mark.cave-ayland@ilande.co.uk \
    --cc=peter.maydell@linaro.org \
    --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.