]> xenbits.xensource.com Git - people/dwmw2/xen.git/commit
AMD/IOMMU: don't "add" IOMMUs
authorJan Beulich <jbeulich@suse.com>
Thu, 27 Jun 2019 10:34:24 +0000 (12:34 +0200)
committerJan Beulich <jbeulich@suse.com>
Thu, 27 Jun 2019 10:34:24 +0000 (12:34 +0200)
commit757122c0cf35281618e80cdab37f4f44e5e5ff55
treeedc26ebbf3195dd5e57822794e166f97a9dbc5d6
parent1bef4b1efd40b4c8c9e7afcd0155042a47896cb0
AMD/IOMMU: don't "add" IOMMUs

For find_iommu_for_device() to consistently (independent of ACPI tables)
return NULL for the PCI devices corresponding to IOMMUs, make sure
IOMMUs don't get mapped to themselves by ivrs_mappings[].

While amd_iommu_add_device() won't be called for IOMMUs from
pci_add_device(), as IOMMUs have got marked r/o,
_setup_hwdom_pci_devices() calls there nevertheless. Avoid issuing the
bogus debugging only "No iommu for ...; cannot be handed to ..." log
message as well as the non-debugging "setup ... for ... failed (-19)"
one.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>
Acked-by: Brian Woods <brian.woods@amd.com>
xen/drivers/passthrough/amd/iommu_acpi.c
xen/drivers/passthrough/amd/pci_amd_iommu.c