On 3/5/25 08:12, Philippe Mathieu-Daudé wrote:
> In preparation of having a single binary for both ARM and
> Aarch64 targets, unify raspi & aspeed by replacing the
> compile-time TARGET_AARCH64 check by a QOM runtime call
> on legacy_binary_is_64bit().
>
> No behavior change with current binaries:
>
> $ ./qemu-system-arm -M help | fgrep raspi
> raspi0 Raspberry Pi Zero (revision 1.2)
> raspi1ap Raspberry Pi A+ (revision 1.1)
> raspi2b Raspberry Pi 2B (revision 1.1)
>
> $ ./qemu-system-aarch64 -M help | fgrep raspi
> raspi0 Raspberry Pi Zero (revision 1.2)
> raspi1ap Raspberry Pi A+ (revision 1.1)
> raspi2b Raspberry Pi 2B (revision 1.1)
> raspi3ap Raspberry Pi 3A+ (revision 1.0)
> raspi3b Raspberry Pi 3B (revision 1.2)
> raspi4b Raspberry Pi 4B (revision 1.5)
>
To see an effect on those changes, we should ideally make sure those
files can compile while being common (in meson.build system_ss), so we
are sure they don't depend on target define anymore.
> Based-on: <20250305153929.43687-1-philmd@linaro.org>
>
> Philippe Mathieu-Daudé (4):
> qom: Introduce TypeInfo::registerable() callback
> hw/arm/raspi: Replace TARGET_AARCH64 by legacy_binary_is_64bit()
> hw/arm/aspeed: Replace TARGET_AARCH64 by legacy_binary_is_64bit()
> hw/ppc: Remove TARGET_PPC64 use in ppc_create_page_sizes_prop()
>
> include/qom/object.h | 1 +
> hw/arm/aspeed.c | 8 ++------
> hw/arm/bcm2836.c | 6 ++----
> hw/arm/raspi.c | 7 +++----
> hw/ppc/fdt.c | 5 +++--
> qom/object.c | 4 ++++
> qom/trace-events | 1 +
> 7 files changed, 16 insertions(+), 16 deletions(-)
>