Yes, will add.From: Baolu Lu<baolu.lu@xxxxxxxxxxxxxxx>To avoid confusion this is not about invalidation of pasid cache itself
Sent: Thursday, March 2, 2023 10:07 PM
+Do you need to consider pasid cache invalidation?
+ if (hw_pass_through && domain_type_is_si(dmar_domain))
+ ret = intel_pasid_setup_pass_through(iommu,
dmar_domain,
+ dev, pasid);
+ else if (dmar_domain->use_first_level)
+ ret = domain_setup_first_level(iommu, dmar_domain,
+ dev, pasid);
+ else
+ ret = intel_pasid_setup_second_level(iommu,
dmar_domain,
+ dev, pasid);
+
+ return ret;
+}
which should be covered by above setup functions already.
Here actually means per-PASID invalidation in iotlb and devtlb. Today
only RID is tracked per domain for invalidation. it needs extension to
walk attached pasid too.
For the set up path, there is no need to flush IOTLBs, because we're going
from non present to present.
On the remove path, IOTLB flush should be covered when device driver
calls iommu_detach_device_pasid(). Covered with this patch.