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

Re: [PATCH v8 6/7] xen/arm: switch Arm to use asm-generic/device.h



Hi Oleksii,

On 09/02/2024 18:00, Oleksii Kurochko wrote:
The following changes were done as a result of switching to
asm-generic/device.h:
  * DEVICE_GIC was renamed to DEVICE_INTERRUPT_CONTROLLER according
    to definition of enum device_class in asm-generic/device.h.
  * acpi-related things in Arm code were guarded by #ifdef CONFIG_ACPI
    as struct acpi_device_desc was guarded in asm-generic, also functions
    acpi_device_init() was guarded too as they are using structure
    acpi_device_desc inside.
  * drop arm/include/asm/device.h and update arm/include/asm/Makefile
    to use asm-generic/device.h instead.

Signed-off-by: Oleksii Kurochko <oleksii.kurochko@xxxxxxxxx>
---
Changes in V8:
  - update the commit message
---
Changes in V7:
  - newly introduced patch which is based on the previous version of the patch:
      [PATCH v6 9/9] xen/asm-generic: introduce generic device.h
---
  xen/arch/arm/device.c             |   5 ++
  xen/arch/arm/domain_build.c       |   2 +-
  xen/arch/arm/gic-v2.c             |   4 +-
  xen/arch/arm/gic-v3.c             |   6 +-
  xen/arch/arm/gic.c                |   4 +-
  xen/arch/arm/include/asm/Makefile |   1 +
  xen/arch/arm/include/asm/device.h | 124 ------------------------------
  7 files changed, 14 insertions(+), 132 deletions(-)
  delete mode 100644 xen/arch/arm/include/asm/device.h

diff --git a/xen/arch/arm/device.c b/xen/arch/arm/device.c
index 1f631d3274..3e02cff008 100644
--- a/xen/arch/arm/device.c
+++ b/xen/arch/arm/device.c
@@ -16,7 +16,10 @@
  #include <xen/lib.h>
extern const struct device_desc _sdevice[], _edevice[];
+
+#ifdef CONFIG_ACPI
  extern const struct acpi_device_desc _asdevice[], _aedevice[];
+#endif

Can you also update the linker script to protect the following code? I.e

#ifdef CONFIG_ACPI
  . = ALIGN(8);
  .adev.info : {
      _asdevice = .;
      *(.adev.info)
      _aedevice = .;
  } :text
#endif

With this change:

Reviewed-by: Julien Grall <jgrall@xxxxxxxxxx>

Cheers,

--
Julien Grall



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.