Skip to content

Commit 88530f0

Browse files
committed
iommu/vt-d: Disable PCI ATS in legacy passthrough mode
jira LE-1907 Rebuild_History Non-Buildable kernel-5.14.0-427.18.1.el9_4 commit-author Lu Baolu <baolu.lu@linux.intel.com> commit da37ddd When IOMMU hardware operates in legacy mode, the TT field of the context entry determines the translation type, with three supported types (Section 9.3 Context Entry): - DMA translation without device TLB support - DMA translation with device TLB support - Passthrough mode with translated and translation requests blocked Device TLB support is absent when hardware is configured in passthrough mode. Disable the PCI ATS feature when IOMMU is configured for passthrough translation type in legacy (non-scalable) mode. Fixes: 0faa19a ("iommu/vt-d: Decouple PASID & PRI enabling from SVA") Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com> Reviewed-by: Kevin Tian <kevin.tian@intel.com> Link: https://lore.kernel.org/r/20231114011036.70142-3-baolu.lu@linux.intel.com Signed-off-by: Joerg Roedel <jroedel@suse.de> (cherry picked from commit da37ddd) Signed-off-by: Jonathan Maple <jmaple@ciq.com>
1 parent 0d62e2d commit 88530f0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

drivers/iommu/intel/iommu.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2487,7 +2487,8 @@ static int dmar_domain_attach_device(struct dmar_domain *domain,
24872487
return ret;
24882488
}
24892489

2490-
iommu_enable_pci_caps(info);
2490+
if (sm_supported(info->iommu) || !domain_type_is_si(info->domain))
2491+
iommu_enable_pci_caps(info);
24912492

24922493
return 0;
24932494
}

0 commit comments

Comments
 (0)