]> git.ipfire.org Git - thirdparty/qemu.git/commitdiff
hw/core: Move the ARM sysbus-fdt to core
authorAlistair Francis <alistair.francis@wdc.com>
Wed, 27 Apr 2022 23:41:42 +0000 (09:41 +1000)
committerAlistair Francis <alistair.francis@wdc.com>
Fri, 29 Apr 2022 00:48:26 +0000 (10:48 +1000)
The ARM virt machine currently uses sysbus-fdt to create device tree
entries for dynamically created MMIO devices.

The RISC-V virt machine can also benefit from this, so move the code to
the core directory.

Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
Reviewed-by: Edgar E. Iglesias <edgar.iglesias@amd.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Message-Id: <20220427234146.1130752-3-alistair.francis@opensource.wdc.com>
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
hw/arm/meson.build
hw/arm/virt.c
hw/arm/xlnx-versal-virt.c
hw/core/meson.build
hw/core/sysbus-fdt.c [moved from hw/arm/sysbus-fdt.c with 99% similarity]
include/hw/core/sysbus-fdt.h [moved from include/hw/arm/sysbus-fdt.h with 100% similarity]

index 721a8eb8beddc6eff8eaf56231d463db9a889ffd..122e5dd992c9363b150bd237878906e33ce6f7d2 100644 (file)
@@ -1,6 +1,5 @@
 arm_ss = ss.source_set()
 arm_ss.add(files('boot.c'), fdt)
-arm_ss.add(when: 'CONFIG_PLATFORM_BUS', if_true: files('sysbus-fdt.c'))
 arm_ss.add(when: 'CONFIG_ARM_VIRT', if_true: files('virt.c'))
 arm_ss.add(when: 'CONFIG_ACPI', if_true: files('virt-acpi-build.c'))
 arm_ss.add(when: 'CONFIG_DIGIC', if_true: files('digic_boards.c'))
index 5bdd98e4a1fffb0979ace3a797a3de781e6ecfcb..f94278935f5a610060043b42f4997dd3021b2a20 100644 (file)
@@ -56,7 +56,7 @@
 #include "qemu/module.h"
 #include "hw/pci-host/gpex.h"
 #include "hw/virtio/virtio-pci.h"
-#include "hw/arm/sysbus-fdt.h"
+#include "hw/core/sysbus-fdt.h"
 #include "hw/platform-bus.h"
 #include "hw/qdev-properties.h"
 #include "hw/arm/fdt.h"
index 66a2de7e133ea33d1e058f4fad963f182910e58f..37fc9b919c07ed16be5f9703cb64cde7c3865d6a 100644 (file)
@@ -15,7 +15,6 @@
 #include "sysemu/device_tree.h"
 #include "hw/boards.h"
 #include "hw/sysbus.h"
-#include "hw/arm/sysbus-fdt.h"
 #include "hw/arm/fdt.h"
 #include "cpu.h"
 #include "hw/qdev-properties.h"
index 0f884d6fd4d2764ab6893817cfc840fdacdd6bd9..7a4d02b6c05029f99a842069ec68bbc58c2d77a4 100644 (file)
@@ -33,6 +33,7 @@ softmmu_ss.add(when: 'CONFIG_PTIMER', if_true: files('ptimer.c'))
 softmmu_ss.add(when: 'CONFIG_REGISTER', if_true: files('register.c'))
 softmmu_ss.add(when: 'CONFIG_SPLIT_IRQ', if_true: files('split-irq.c'))
 softmmu_ss.add(when: 'CONFIG_XILINX_AXI', if_true: files('stream.c'))
+softmmu_ss.add(when: 'CONFIG_PLATFORM_BUS', if_true: files('sysbus-fdt.c'))
 
 softmmu_ss.add(files(
   'cpu-sysemu.c',
similarity index 99%
rename from hw/arm/sysbus-fdt.c
rename to hw/core/sysbus-fdt.c
index 48c5fe9bf18b08b5c23f30e07d8f8cc90679dac7..19d22cbe73014b4d44931b66685ba2c662c4ca6f 100644 (file)
@@ -27,7 +27,7 @@
 #ifdef CONFIG_LINUX
 #include <linux/vfio.h>
 #endif
-#include "hw/arm/sysbus-fdt.h"
+#include "hw/core/sysbus-fdt.h"
 #include "qemu/error-report.h"
 #include "sysemu/device_tree.h"
 #include "sysemu/tpm.h"