[PATCH v4 23/35] drivers/arm: Implement acpi_fill_madt

Patrick Rudolph patrick.rudolph at 9elements.com
Mon Sep 23 07:48:55 CEST 2024


On Thu, Sep 19, 2024 at 4:12 PM Simon Glass <sjg at chromium.org> wrote:
>
> On Wed, 18 Sept 2024 at 17:22, Patrick Rudolph
> <patrick.rudolph at 9elements.com> wrote:
> >
> > Fill the MADT table in the GICV3 driver and armv8 CPU driver to
> > drop SoC specific code. While the GIC only needs devicetree
> > data, the CPU driver needs additional information stored in
> > the cpu_plat struct.
> >
> > While on it update the only board making use of the existing
> > drivers and writing ACPI MADT in mainboard code.
> >
> > TEST: Booted on QEMU sbsa-ref using GICV3 driver model generated MADT.
> >       Booted on QEMU raspb4 using GICV2 driver model generated MADT.
> >
> > Signed-off-by: Patrick Rudolph <patrick.rudolph at 9elements.com>
> > Cc: Simon Glass <sjg at chromium.org>
> > ---
> > Changelog v4:
> > - Read everything from the DT
> > - Export armv8_cpu_fill_madt() to use it in other CPU drivers
> > - Depend on IRQ
> >
> > ---
> >  arch/arm/lib/gic-v3-its.c | 89 ++++++++++++++++++++++++++++++++++++++-
> >  drivers/cpu/Kconfig       |  1 +
> >  drivers/cpu/armv8_cpu.c   | 80 ++++++++++++++++++++++++++++++++++-
> >  drivers/cpu/armv8_cpu.h   | 10 +++++
> >  4 files changed, 178 insertions(+), 2 deletions(-)
> >
>
> Reviewed-by: Simon Glass <sjg at chromium.org>
>
> I'm still not sure why you are using u64 instead of ulong?

u64 is the type defined in the ACPI spec for the fields within the
ACPI MADT table.
It's also valid for 32-bit systems, even though this code is supposed
to run on 64-bit only.


More information about the U-Boot mailing list