Skip to content

Commit 4e589a5

Browse files
LuBaolujoergroedel
authored andcommitted
iommu/vt-d: Use cache_tag_flush_all() in flush_iotlb_all
The flush_iotlb_all callback is called by the iommu core to flush all caches for the affected domain. Use cache_tag_flush_all() in this callback. Signed-off-by: Lu Baolu <[email protected]> Reviewed-by: Kevin Tian <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Joerg Roedel <[email protected]>
1 parent 446a68c commit 4e589a5

File tree

1 file changed

+1
-19
lines changed

1 file changed

+1
-19
lines changed

drivers/iommu/intel/iommu.c

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1557,25 +1557,7 @@ static void parent_domain_flush(struct dmar_domain *domain,
15571557

15581558
static void intel_flush_iotlb_all(struct iommu_domain *domain)
15591559
{
1560-
struct dmar_domain *dmar_domain = to_dmar_domain(domain);
1561-
struct iommu_domain_info *info;
1562-
unsigned long idx;
1563-
1564-
xa_for_each(&dmar_domain->iommu_array, idx, info) {
1565-
struct intel_iommu *iommu = info->iommu;
1566-
u16 did = domain_id_iommu(dmar_domain, iommu);
1567-
1568-
if (dmar_domain->use_first_level)
1569-
domain_flush_pasid_iotlb(iommu, dmar_domain, 0, -1, 0);
1570-
else
1571-
iommu->flush.flush_iotlb(iommu, did, 0, 0,
1572-
DMA_TLB_DSI_FLUSH);
1573-
1574-
iommu_flush_dev_iotlb(dmar_domain, 0, MAX_AGAW_PFN_WIDTH);
1575-
}
1576-
1577-
if (dmar_domain->nested_parent)
1578-
parent_domain_flush(dmar_domain, 0, -1, 0);
1560+
cache_tag_flush_all(to_dmar_domain(domain));
15791561
}
15801562

15811563
static void iommu_disable_protect_mem_regions(struct intel_iommu *iommu)

0 commit comments

Comments
 (0)