Skip to content

Commit 86e5ca0

Browse files
jgunthorpewilldeacon
authored andcommitted
iommu/arm-smmu-v3: Do not ATC invalidate the entire domain
At this point we know which master we are going to change the PCI config on, this is the only device we need to invalidate. Switch arm_smmu_atc_inv_domain() for arm_smmu_atc_inv_master(). Tested-by: Nicolin Chen <[email protected]> Tested-by: Shameer Kolothum <[email protected]> Reviewed-by: Michael Shavit <[email protected]> Reviewed-by: Nicolin Chen <[email protected]> Reviewed-by: Moritz Fischer <[email protected]> Reviewed-by: Mostafa Saleh <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Will Deacon <[email protected]>
1 parent fdc69d3 commit 86e5ca0

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2410,7 +2410,10 @@ static void arm_smmu_enable_ats(struct arm_smmu_master *master,
24102410
pdev = to_pci_dev(master->dev);
24112411

24122412
atomic_inc(&smmu_domain->nr_ats_masters);
2413-
arm_smmu_atc_inv_domain(smmu_domain, IOMMU_NO_PASID, 0, 0);
2413+
/*
2414+
* ATC invalidation of PASID 0 causes the entire ATC to be flushed.
2415+
*/
2416+
arm_smmu_atc_inv_master(master);
24142417
if (pci_enable_ats(pdev, stu))
24152418
dev_err(master->dev, "Failed to enable ATS (STU %zu)\n", stu);
24162419
}

0 commit comments

Comments
 (0)