qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [RFC PATCH-for-10.1 00/39] single-binary: Make hw/arm/ common
@ 2025-04-03 23:57 Philippe Mathieu-Daudé
  2025-04-03 23:57 ` [RFC PATCH-for-10.1 01/39] target/arm: Implement per-binary TargetInfo structures Philippe Mathieu-Daudé
                   ` (39 more replies)
  0 siblings, 40 replies; 68+ messages in thread
From: Philippe Mathieu-Daudé @ 2025-04-03 23:57 UTC (permalink / raw)
  To: qemu-devel
  Cc: Alex Bennée, Pierrick Bouvier, Richard Henderson,
	Markus Armbruster

Hi,

At this point this series is mostly a draft for Pierrick.

After introducing the generic TargetInfo API [*], we implement
the ARM variants, then use the API to remove target-specific code,
allowing to eventually remove the target-specific arm_ss[] source
set in meson.build, having all objects in arm_common_ss[].
Various header cleanups are necessary before getting there.

Regards,

Phil.

Available here, based on tcg-next:
https://gitlab.com/philmd/qemu/-/tags/single-binary-hw-arm-rfc-v1

[*] https://lore.kernel.org/qemu-devel/20250403234914.9154-1-philmd@linaro.org/

Philippe Mathieu-Daudé (39):
  target/arm: Implement per-binary TargetInfo structures
  target/arm: Register TYPE_BINARY_QEMU_SYSTEM_ARM/AARCH64 interfaces
  target/arm: Filter CPU types for binary
  hw/arm: Filter machine types for binary
  hw/arm/aspeed: Filter machine types for binary
  hw/arm/aspeed: Build objects once
  hw/arm/raspi: Filter machine types for binary
  hw/arm/raspi: Build objects once
  target/arm/cpregs: Include missing 'target/arm/cpu.h' header
  hw/arm/boot: Include missing 'system/memory.h' header
  hw/arm: Use full "target/arm/cpu.h" path to include target's "cpu.h"
  target/arm/cpu-features: Include missing 'cpu.h' header
  target/arm/qmp: Include missing 'cpu.h' header
  target/arm/kvm: Include missing 'cpu-qom.h' header
  target/arm/hvf: Include missing 'cpu-qom.h' header
  hw/arm: Remove unnecessary 'cpu.h' header
  target/arm: Restrict inclusion of 'multiprocessing.h'
  target/arm: Move some definitions from 'cpu.h' to 'multiprocessing.h'
  hw/arm: Include missing 'target/arm/gtimer.h' header
  target/arm: Extract PSCI definitions to 'psci.h'
  target/arm: Extract feature definitions to 'cpu_has_feature.h' header
  target/arm: Add arm_cpu_has_feature() helper
  hw/arm/realview: Replace arm_feature() -> arm_cpu_has_feature()
  hw/arm/virt-acpi: Replace arm_feature() -> arm_cpu_has_feature()
  hw/arm: Build virt-acpi-build.c once
  system/hvf: Avoid including 'cpu.h'
  system/hvf: Expose hvf_enabled() to common code
  exec: Do not poison hardware accelerators
  hw/arm: Build sbsa-ref.c once
  target/arm: Replace target_ulong -> hwaddr in ARMMMUFaultInfo
  target/arm: Replace target_ulong -> uint64_t for HWBreakpoint
  target/arm: Replace target_ulong -> vaddr for CPUWatchpoint
  hw/core/machine: Allow dynamic registration of valid CPU types
  hw/arm/virt: Register valid CPU types dynamically
  hw/arm/virt: Replace TARGET_AARCH64 -> target_long_bits()
  target/arm: Expose Aarch64 helpers indistinctly
  hw/arm: Build virt.c once
  hw/arm: Move xen files to arm_common_ss[]
  hw/arm/meson: Remove arm_ss[] source set

 MAINTAINERS                              |  1 +
 meson.build                              |  1 +
 include/exec/poison.h                    |  4 --
 include/hw/arm/boot.h                    |  3 +-
 include/hw/arm/digic.h                   |  2 +-
 include/hw/arm/fsl-imx6.h                |  2 +-
 include/hw/arm/fsl-imx6ul.h              |  2 +-
 include/hw/arm/fsl-imx7.h                |  2 +-
 include/hw/arm/fsl-imx8mp.h              |  2 +-
 include/hw/boards.h                      |  8 +++
 include/qemu/target_info-qom.h           | 20 ++++++
 include/system/hvf.h                     | 17 ++++--
 include/system/hvf_int.h                 |  2 +
 target/arm/cpregs.h                      |  1 +
 target/arm/cpu-features.h                |  1 +
 target/arm/cpu.h                         | 78 +-----------------------
 target/arm/cpu_has_feature.h             | 67 ++++++++++++++++++++
 target/arm/hvf_arm.h                     |  2 +-
 target/arm/internals.h                   | 22 +++----
 target/arm/kvm_arm.h                     |  1 +
 target/arm/multiprocessing.h             | 18 ++++++
 target/arm/psci.h                        | 18 ++++++
 accel/stubs/hvf-stub.c                   | 12 ++++
 hw/arm/aspeed.c                          | 30 ++++++---
 hw/arm/aspeed_ast2600.c                  |  1 +
 hw/arm/aspeed_ast27x0.c                  |  2 +
 hw/arm/b-l475e-iot01a.c                  |  1 +
 hw/arm/bananapi_m2u.c                    |  1 +
 hw/arm/bcm2836.c                         |  4 --
 hw/arm/bcm2838.c                         |  1 +
 hw/arm/boot.c                            |  2 +
 hw/arm/collie.c                          |  1 +
 hw/arm/exynos4210.c                      |  3 +-
 hw/arm/exynos4_boards.c                  |  1 +
 hw/arm/fby35.c                           |  1 +
 hw/arm/fsl-imx8mp.c                      |  1 +
 hw/arm/highbank.c                        |  4 +-
 hw/arm/imx8mp-evk.c                      |  1 +
 hw/arm/mcimx6ul-evk.c                    |  1 +
 hw/arm/mcimx7d-sabre.c                   |  1 +
 hw/arm/microbit.c                        |  1 +
 hw/arm/mps2-tz.c                         |  4 ++
 hw/arm/mps2.c                            |  4 ++
 hw/arm/mps3r.c                           |  3 +-
 hw/arm/musca.c                           |  2 +
 hw/arm/npcm8xx.c                         |  2 +
 hw/arm/omap_sx1.c                        |  2 +
 hw/arm/orangepi.c                        |  1 +
 hw/arm/raspi.c                           |  9 +--
 hw/arm/raspi4b.c                         |  1 +
 hw/arm/realview.c                        | 14 +++--
 hw/arm/sbsa-ref.c                        |  3 +
 hw/arm/smmuv3.c                          |  1 -
 hw/arm/stellaris.c                       |  3 +
 hw/arm/versatilepb.c                     |  1 +
 hw/arm/vexpress.c                        |  2 +
 hw/arm/virt-acpi-build.c                 |  4 +-
 hw/arm/virt.c                            | 44 +++++++------
 hw/arm/xilinx_zynq.c                     |  1 +
 hw/arm/xlnx-versal-virt.c                |  2 +
 hw/arm/xlnx-zcu102.c                     |  2 +
 hw/core/machine.c                        | 28 +++++++++
 hw/vmapple/vmapple.c                     |  3 +
 target/arm/arm-qmp-cmds.c                |  1 +
 target/arm/cpu.c                         | 10 +++
 target/arm/cpu64.c                       |  2 +
 target/arm/helper.c                      |  1 +
 target/arm/hvf/hvf.c                     |  1 +
 target/arm/hyp_gdbstub.c                 | 14 ++---
 target/arm/kvm.c                         |  1 +
 target/arm/target_info-aarch64-softmmu.c | 24 ++++++++
 target/arm/target_info-arm-softmmu.c     | 24 ++++++++
 target/arm/tcg/op_helper.c               |  2 +
 target/arm/tcg/psci.c                    |  1 +
 target_info-qom.c                        |  8 +++
 accel/stubs/meson.build                  |  1 +
 hw/arm/meson.build                       | 22 ++++---
 scripts/make-config-poison.sh            |  4 ++
 target/arm/meson.build                   |  5 ++
 79 files changed, 429 insertions(+), 171 deletions(-)
 create mode 100644 target/arm/cpu_has_feature.h
 create mode 100644 target/arm/psci.h
 create mode 100644 accel/stubs/hvf-stub.c
 create mode 100644 target/arm/target_info-aarch64-softmmu.c
 create mode 100644 target/arm/target_info-arm-softmmu.c

-- 
2.47.1



^ permalink raw reply	[flat|nested] 68+ messages in thread

end of thread, other threads:[~2025-05-06 15:00 UTC | newest]

Thread overview: 68+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-04-03 23:57 [RFC PATCH-for-10.1 00/39] single-binary: Make hw/arm/ common Philippe Mathieu-Daudé
2025-04-03 23:57 ` [RFC PATCH-for-10.1 01/39] target/arm: Implement per-binary TargetInfo structures Philippe Mathieu-Daudé
2025-04-04 18:16   ` Pierrick Bouvier
2025-04-03 23:57 ` [RFC PATCH-for-10.1 02/39] target/arm: Register TYPE_BINARY_QEMU_SYSTEM_ARM/AARCH64 interfaces Philippe Mathieu-Daudé
2025-04-03 23:57 ` [RFC PATCH-for-10.1 03/39] target/arm: Filter CPU types for binary Philippe Mathieu-Daudé
2025-04-04 18:17   ` Pierrick Bouvier
2025-04-03 23:57 ` [RFC PATCH-for-10.1 04/39] hw/arm: Filter machine " Philippe Mathieu-Daudé
2025-04-03 23:57 ` [RFC PATCH-for-10.1 05/39] hw/arm/aspeed: " Philippe Mathieu-Daudé
2025-04-03 23:57 ` [RFC PATCH-for-10.1 06/39] hw/arm/aspeed: Build objects once Philippe Mathieu-Daudé
2025-04-03 23:57 ` [RFC PATCH-for-10.1 07/39] hw/arm/raspi: Filter machine types for binary Philippe Mathieu-Daudé
2025-04-03 23:57 ` [RFC PATCH-for-10.1 08/39] hw/arm/raspi: Build objects once Philippe Mathieu-Daudé
2025-04-03 23:57 ` [RFC PATCH-for-10.1 09/39] target/arm/cpregs: Include missing 'target/arm/cpu.h' header Philippe Mathieu-Daudé
2025-04-03 23:57 ` [RFC PATCH-for-10.1 10/39] hw/arm/boot: Include missing 'system/memory.h' header Philippe Mathieu-Daudé
2025-04-03 23:57 ` [RFC PATCH-for-10.1 11/39] hw/arm: Use full "target/arm/cpu.h" path to include target's "cpu.h" Philippe Mathieu-Daudé
2025-04-04 18:20   ` Pierrick Bouvier
2025-04-04 21:53     ` Philippe Mathieu-Daudé
2025-04-05  1:03       ` Pierrick Bouvier
2025-04-05 14:27         ` Philippe Mathieu-Daudé
2025-04-07 17:13           ` Pierrick Bouvier
2025-04-03 23:57 ` [RFC PATCH-for-10.1 12/39] target/arm/cpu-features: Include missing 'cpu.h' header Philippe Mathieu-Daudé
2025-04-03 23:57 ` [RFC PATCH-for-10.1 13/39] target/arm/qmp: " Philippe Mathieu-Daudé
2025-04-03 23:57 ` [RFC PATCH-for-10.1 14/39] target/arm/kvm: Include missing 'cpu-qom.h' header Philippe Mathieu-Daudé
2025-04-03 23:57 ` [RFC PATCH-for-10.1 15/39] target/arm/hvf: " Philippe Mathieu-Daudé
2025-04-03 23:57 ` [RFC PATCH-for-10.1 16/39] hw/arm: Remove unnecessary 'cpu.h' header Philippe Mathieu-Daudé
2025-04-03 23:57 ` [RFC PATCH-for-10.1 17/39] target/arm: Restrict inclusion of 'multiprocessing.h' Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 18/39] target/arm: Move some definitions from 'cpu.h' to 'multiprocessing.h' Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 19/39] hw/arm: Include missing 'target/arm/gtimer.h' header Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 20/39] target/arm: Extract PSCI definitions to 'psci.h' Philippe Mathieu-Daudé
2025-04-04 18:21   ` Pierrick Bouvier
2025-04-04 21:54     ` Philippe Mathieu-Daudé
2025-04-05  1:03       ` Pierrick Bouvier
2025-04-05 14:43         ` Philippe Mathieu-Daudé
2025-04-07 17:25           ` Pierrick Bouvier
2025-04-03 23:58 ` [RFC PATCH-for-10.1 21/39] target/arm: Extract feature definitions to 'cpu_has_feature.h' header Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 22/39] target/arm: Add arm_cpu_has_feature() helper Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 23/39] hw/arm/realview: Replace arm_feature() -> arm_cpu_has_feature() Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 24/39] hw/arm/virt-acpi: " Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 25/39] hw/arm: Build virt-acpi-build.c once Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 26/39] system/hvf: Avoid including 'cpu.h' Philippe Mathieu-Daudé
2025-05-06 14:14   ` Philippe Mathieu-Daudé
2025-05-06 15:00     ` Pierrick Bouvier
2025-04-03 23:58 ` [RFC PATCH-for-10.1 27/39] system/hvf: Expose hvf_enabled() to common code Philippe Mathieu-Daudé
2025-04-04 18:23   ` Pierrick Bouvier
2025-04-04 21:56     ` Philippe Mathieu-Daudé
2025-04-05  1:05       ` Pierrick Bouvier
2025-04-03 23:58 ` [RFC PATCH-for-10.1 28/39] exec: Do not poison hardware accelerators Philippe Mathieu-Daudé
2025-04-04 18:25   ` Pierrick Bouvier
2025-04-04 22:00     ` Philippe Mathieu-Daudé
2025-04-05  1:07       ` Pierrick Bouvier
2025-04-03 23:58 ` [RFC PATCH-for-10.1 29/39] hw/arm: Build sbsa-ref.c once Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 30/39] target/arm: Replace target_ulong -> hwaddr in ARMMMUFaultInfo Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 31/39] target/arm: Replace target_ulong -> uint64_t for HWBreakpoint Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 32/39] target/arm: Replace target_ulong -> vaddr for CPUWatchpoint Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 33/39] hw/core/machine: Allow dynamic registration of valid CPU types Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 34/39] hw/arm/virt: Register valid CPU types dynamically Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 35/39] hw/arm/virt: Replace TARGET_AARCH64 -> target_long_bits() Philippe Mathieu-Daudé
2025-04-04 18:28   ` Pierrick Bouvier
2025-04-04 22:05     ` Philippe Mathieu-Daudé
2025-04-05  1:10       ` Pierrick Bouvier
2025-04-03 23:58 ` [RFC PATCH-for-10.1 36/39] target/arm: Expose Aarch64 helpers indistinctly Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 37/39] hw/arm: Build virt.c once Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 38/39] hw/arm: Move xen files to arm_common_ss[] Philippe Mathieu-Daudé
2025-04-04 14:40   ` Philippe Mathieu-Daudé
2025-04-03 23:58 ` [RFC PATCH-for-10.1 39/39] hw/arm/meson: Remove arm_ss[] source set Philippe Mathieu-Daudé
2025-04-04 17:12 ` [RFC PATCH-for-10.1 00/39] single-binary: Make hw/arm/ common Pierrick Bouvier
2025-04-04 18:04   ` Philippe Mathieu-Daudé
2025-04-04 18:30     ` Pierrick Bouvier
2025-04-04 18:33   ` Pierrick Bouvier

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).