Message ID | 9283e3f46e258ae7998fa4c7254b8a7885f98e1c.camel@nedap.com |
---|---|
State | Superseded |
Delegated to: | Tom Rini |
Headers | show |
Series | mmc support for QEMU | expand |
On Fri, 30 Oct 2020 at 02:45, Harm Berntsen <harm.berntsen@nedap.com> wrote: > > The only platforms with an asm/acpi_table.h file are X86 and Sandbox. > Some drivers, i.e. pci_mmc.c, can generate ACPI info and therefore > include asm/acpi_table.h by proxy. This commit ensures that the > platforms wishing to use such driver and do not have ACPI support do not > fail on this include. The if defined structure is also used in other > places to conditionally include asm headers, i.e. > arch/arm/include/asm/gpio.h > > Signed-off-by: Harm Berntsen <harm.berntsen@nedap.com> > CC: Simon Glass <sjg@chromium.org> > --- > > include/acpi/acpi_table.h | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/include/acpi/acpi_table.h b/include/acpi/acpi_table.h > index abbca6530d..8d9d0f8d19 100644 > --- a/include/acpi/acpi_table.h > +++ b/include/acpi/acpi_table.h > @@ -690,6 +690,8 @@ void acpi_setup_base_tables(struct acpi_ctx *ctx, void *start); > > #endif /* !__ACPI__*/ > > +#if defined(CONFIG_X86) || defined(CONFIG_SANDBOX) > #include <asm/acpi_table.h> > +#endif Reviewed-by: Simon Glass <sjg@chromium.org> But how about adding an empty file for the other architecture? > > #endif /* __ACPI_TABLE_H__ */ >
diff --git a/include/acpi/acpi_table.h b/include/acpi/acpi_table.h index abbca6530d..8d9d0f8d19 100644 --- a/include/acpi/acpi_table.h +++ b/include/acpi/acpi_table.h @@ -690,6 +690,8 @@ void acpi_setup_base_tables(struct acpi_ctx *ctx, void *start); #endif /* !__ACPI__*/ +#if defined(CONFIG_X86) || defined(CONFIG_SANDBOX) #include <asm/acpi_table.h> +#endif #endif /* __ACPI_TABLE_H__ */
The only platforms with an asm/acpi_table.h file are X86 and Sandbox. Some drivers, i.e. pci_mmc.c, can generate ACPI info and therefore include asm/acpi_table.h by proxy. This commit ensures that the platforms wishing to use such driver and do not have ACPI support do not fail on this include. The if defined structure is also used in other places to conditionally include asm headers, i.e. arch/arm/include/asm/gpio.h Signed-off-by: Harm Berntsen <harm.berntsen@nedap.com> CC: Simon Glass <sjg@chromium.org> --- include/acpi/acpi_table.h | 2 ++ 1 file changed, 2 insertions(+)