On 20/03/2019 20:22, Igor Druzhinin wrote:
> Since commit dcf41790 ("x86/mmcfg/drhd: Move acpi_mmcfg_init() call
> before calling acpi_parse_dmar()") PCI segment 0 is now known early
> which made the sanity check on DRHD definition structure to work.
> This, in turn, caused a regression on some machines (in particular,
> HP PowerEdge R740 with I/O AT DMA disabled) where IOMMU was explicitly
> disabled due to some internal PCI devices being non-discoverable but
> present in DMAR.
>
> While this is indeed a BIOS mistake it seems to be not that critical
> to disable the whole IOMMU. Instead, extend the scope of
> "workaround_bios_bug" option and make it enabled by default. This is
> consistent with our documentation and actually what a user might expect
> from an option with that name. It also doesn't seem safe to simply ignore
> DRHD without initialization so remove this case. But leave the original
> DMAR check in place to still allow error reporting.
>
> Signed-off-by: Igor Druzhinin <igor.druzhi...@citrix.com>

This is code which was previously dead.  The behaviour of ignoring an
IOMMU because there is unreachable device behind it is awful and
shouldn't exist, but we should at least leave a trace of it in the logs.

TBH, I'd prefer to delete the `workaround_bios_bug` option entirely, and
just print out the bad entries.  Nothing the option does is worthy of
shutting the IOMMU down.

CC-ing Juergen as this is a 4.12 regression.

I can easily spin a patch along my suggested route if others agree.

~Andrew

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

Reply via email to