Skip to content

Commit

Permalink
hw/core: Move the ARM sysbus-fdt to core
Browse files Browse the repository at this point in the history
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 <[email protected]>
Reviewed-by: Edgar E. Iglesias <[email protected]>
Reviewed-by: Bin Meng <[email protected]>
Message-Id: <[email protected]>
Signed-off-by: Alistair Francis <[email protected]>
  • Loading branch information
alistair23 committed Apr 29, 2022
1 parent 1c20d3f commit d24a7bc
Show file tree
Hide file tree
Showing 6 changed files with 3 additions and 4 deletions.
1 change: 0 additions & 1 deletion hw/arm/meson.build
Original file line number Diff line number Diff line change
@@ -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'))
Expand Down
2 changes: 1 addition & 1 deletion hw/arm/virt.c
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down
1 change: 0 additions & 1 deletion hw/arm/xlnx-versal-virt.c
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down
1 change: 1 addition & 0 deletions hw/core/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -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',
Expand Down
2 changes: 1 addition & 1 deletion hw/arm/sysbus-fdt.c → hw/core/sysbus-fdt.c
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down
File renamed without changes.

0 comments on commit d24a7bc

Please sign in to comment.