Re: [PATCH v2] x86: i8237: Register based on FADT legacy boot flag
From: Thomas Gleixner
Date: Mon Mar 19 2018 - 06:57:26 EST
On Mon, 19 Mar 2018, Anshuman Gupta wrote:
> On Wed, Mar 14, 2018 at 04:07:43PM +0100, Thomas Gleixner wrote:
> > On Wed, 14 Mar 2018, Rajneesh Bhardwaj wrote:
> > > + * support 8237 DMA or bus mastering from LPC. Platform firmware
> > > + * must announce the support for such legacy devices via
> > > + * ACPI_FADT_LEGACY_DEVICES field in FADT table.
> > > + */
> > > + if (!x86_platform.legacy.devices.pnpbios && dmi_get_bios_year() >= 2017)
> >
> > Please use arch_pnpbios_disabled() and explain why you need that year
> arch_pnpbios_disabled is defined only when CONFIG_PNPBIOS is set, which may
> not be true for all configurations.
The please create a helper function x86_pnpbios_disabled() and use that one
in arch_pnp_bios_disabled() and in your new code.
> > check. If there is no pnpbios then why is the year interesting and why
> > would anyone trust something which comes from BIOS?
>
> Modern bios fsp have started using to use ACPI_FADT_LEGACY_DEVICES field in
> FADT table, that is the reason we require a year check for BIOS.
> https://review.coreboot.org/#/c/coreboot/+/23833/
> https://review.coreboot.org/#/c/coreboot/+/23835/
Sorry, this gerrit stuff is unreadable. Please explain it in your own
words. You have to do that anyway as that information wants to be in a
comment or at least in the change log.
Thanks,
tglx