qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH] hw/m68k/mcf52xx: Replace hw_error() by qemu_log_mask()


From: Philippe Mathieu-Daudé
Subject: Re: [PATCH] hw/m68k/mcf52xx: Replace hw_error() by qemu_log_mask()
Date: Mon, 18 May 2020 19:24:35 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.5.0

On 5/18/20 7:17 PM, Thomas Huth wrote:
On 18/05/2020 19.08, Philippe Mathieu-Daudé wrote:
On 5/18/20 6:32 PM, Thomas Huth wrote:
On 18/05/2020 11.49, Philippe Mathieu-Daudé wrote:
hw_error() calls exit(). This a bit overkill when we can log
the accesses as unimplemented or guest error.

Good idea. hw_error() is also mainly for CPU errors, it really should
not be used for non-CPU devices.

Are you sure?

$ git grep hw_error target | wc -l
5
$ git grep hw_error hw | wc -l
137

Well, the function is defined in cpus.c and it's dumping the state of
each CPU ... I think it's used in a lot of places during development of
new code to quickly get some information on where things went wrong in
the guest, but technically, it really sounds wrong to me that a non-CPU
device creates CPU dumps in mature code.

OK got it now, thanks.



reply via email to

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