qemu-stable
[Top][All Lists]
Advanced

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

Re: [PATCH for-9.1?] system/vl.c: Print machine name, not "(null)", for


From: Philippe Mathieu-Daudé
Subject: Re: [PATCH for-9.1?] system/vl.c: Print machine name, not "(null)", for unknown machine types
Date: Thu, 22 Aug 2024 15:54:12 +0200
User-agent: Mozilla Thunderbird

On 22/8/24 14:23, Peter Maydell wrote:
In commit 412d294ffdc we tried to improve the error message printed when
the machine type is unknown, but we used the wrong variable, resulting in:

$ ./build/x86/qemu-system-aarch64 -M bang
qemu-system-aarch64: unsupported machine type: "(null)"
Use -machine help to list supported machines

Use the right variable, so we produce more helpful output:

$ ./build/x86/qemu-system-aarch64 -M bang
qemu-system-aarch64: unsupported machine type: "bang"
Use -machine help to list supported machines

Note that we must move the qdict_del() to below the error_setg(),
because machine_type points into the value of that qdict entry,
and deleting it will make the pointer invalid.

Cc: qemu-stable@nongnu.org
Fixes: 412d294ffdc ("vl.c: select_machine(): add selected machine type to error 
message")
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
Tagged as for-9.1 because this is a sort-of regression since 9.0
(in 9.0 we didn't try to print the machine type name at all in
this error). But it's also very close to release and this is only
cosmetics in an error message. The cc-stable is for the case where
we don't put it into 9.1 and then backport it to the 9.1 stable
branch after release.

  system/vl.c | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)

Oops, thanks!

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>




reply via email to

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