Skip to content

Commit 81ebd91

Browse files
LuBaolujoergroedel
authored andcommitted
iommu/vt-d: Remove redundant IOTLB flush
IOTLB flush already included in the PASID tear down and the page request drain process. There is no need to flush again. Signed-off-by: Jacob Pan <[email protected]> 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 66ac4db commit 81ebd91

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

drivers/iommu/intel-svm.c

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -209,11 +209,9 @@ static void intel_mm_release(struct mmu_notifier *mn, struct mm_struct *mm)
209209
* *has* to handle gracefully without affecting other processes.
210210
*/
211211
rcu_read_lock();
212-
list_for_each_entry_rcu(sdev, &svm->devs, list) {
212+
list_for_each_entry_rcu(sdev, &svm->devs, list)
213213
intel_pasid_tear_down_entry(svm->iommu, sdev->dev,
214214
svm->pasid, true);
215-
intel_flush_svm_range_dev(svm, sdev, 0, -1, 0);
216-
}
217215
rcu_read_unlock();
218216

219217
}
@@ -403,7 +401,6 @@ int intel_svm_unbind_gpasid(struct device *dev, int pasid)
403401
intel_pasid_tear_down_entry(iommu, dev,
404402
svm->pasid, false);
405403
intel_svm_drain_prq(dev, svm->pasid);
406-
intel_flush_svm_range_dev(svm, sdev, 0, -1, 0);
407404
kfree_rcu(sdev, rcu);
408405

409406
if (list_empty(&svm->devs)) {
@@ -643,7 +640,6 @@ int intel_svm_unbind_mm(struct device *dev, int pasid)
643640
intel_pasid_tear_down_entry(iommu, dev,
644641
svm->pasid, false);
645642
intel_svm_drain_prq(dev, svm->pasid);
646-
intel_flush_svm_range_dev(svm, sdev, 0, -1, 0);
647643
kfree_rcu(sdev, rcu);
648644

649645
if (list_empty(&svm->devs)) {

0 commit comments

Comments
 (0)