Re: [PATCH v3 5/7] iommu/vt-d: Make the blocked domain support PASID

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 11/4/24 21:20, Yi Liu wrote:
@@ -4291,15 +4296,18 @@ void domain_remove_dev_pasid(struct iommu_domain *domain,
  	kfree(dev_pasid);
  }
-static void intel_iommu_remove_dev_pasid(struct device *dev, ioasid_t pasid,
-					 struct iommu_domain *domain)
+static int blocking_domain_set_dev_pasid(struct iommu_domain *domain,
+					 struct device *dev, ioasid_t pasid,
+					 struct iommu_domain *old)
  {
  	struct device_domain_info *info = dev_iommu_priv_get(dev);
  	struct intel_iommu *iommu = info->iommu;
intel_pasid_tear_down_entry(iommu, dev, pasid, false);
  	intel_drain_pasid_prq(dev, pasid);
-	domain_remove_dev_pasid(domain, dev, pasid);
+	domain_remove_dev_pasid(old, dev, pasid);
+
+	return 0;
  }
struct dev_pasid_info *
@@ -4664,7 +4672,6 @@ const struct iommu_ops intel_iommu_ops = {
  	.dev_disable_feat	= intel_iommu_dev_disable_feat,
  	.is_attach_deferred	= intel_iommu_is_attach_deferred,
  	.def_domain_type	= device_def_domain_type,
-	.remove_dev_pasid	= intel_iommu_remove_dev_pasid,

This will cause iommu_attach_device_pasid() to fail due to the check and
failure condition introduced in patch 1/7.

--
baolu




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux