[Intel-gfx] [PATCH 5/7] iommu/vt-d: Assume BIOS lies about ATSR for integrated gfx
David Woodhouse
dwmw2 at infradead.org
Thu Oct 8 16:53:30 PDT 2015
If the device itself reports ATS in its PCIe capabilities, but the BIOS
neglects to provide an ATSR structure to indicate that the root port can
also cope, then assume the latter is lying.
Signed-off-by: David Woodhouse <David.Woodhouse at intel.com>
---
drivers/iommu/intel-iommu.c | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/drivers/iommu/intel-iommu.c b/drivers/iommu/intel-iommu.c
index a6fd639..b5ab009 100644
--- a/drivers/iommu/intel-iommu.c
+++ b/drivers/iommu/intel-iommu.c
@@ -1447,9 +1447,14 @@ iommu_support_dev_iotlb (struct dmar_domain *domain, struct intel_iommu *iommu,
if (!pci_find_ext_capability(pdev, PCI_EXT_CAP_ID_ATS))
return NULL;
- if (!dmar_find_matched_atsr_unit(pdev))
- return NULL;
-
+ if (!dmar_find_matched_atsr_unit(pdev)) {
+ if (intel_iommu_pasid28 && IS_GFX_DEVICE(pdev) &&
+ pdev->vendor == 0x8086) {
+ pr_warn("BIOS denies ATSR capability for %s; assuming it lies\n",
+ dev_name(info->dev));
+ } else
+ return NULL;
+ }
return info;
}
--
2.4.3
--
David Woodhouse Open Source Technology Centre
David.Woodhouse at intel.com Intel Corporation
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 5691 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/intel-gfx/attachments/20151009/898c2869/attachment.bin>
More information about the Intel-gfx
mailing list