iommu: Store either domain or handle in group->pasid_array
iommu_attach_device_pasid() only stores handle to group->pasid_array when there is a valid handle input. However, it makes the iommu_attach_device_pasid() unable to detect if the pasid has been attached or not previously. To be complete, let the iommu_attach_device_pasid() store the domain to group->pasid_array if no valid handle. The other users of the group->pasid_array should be updated to be consistent. e.g. the iommu_attach_group_handle() and iommu_replace_group_handle(). Link: https://patch.msgid.link/r/20250226011849.5102-4-yi.l.liu@intel.com Suggested-by:Jason Gunthorpe <jgg@nvidia.com> Reviewed-by:
Jason Gunthorpe <jgg@nvidia.com> Reviewed-by:
Nicolin Chen <nicolinc@nvidia.com> Reviewed-by:
Kevin Tian <kevin.tian@intel.com> Signed-off-by:
Yi Liu <yi.l.liu@intel.com> Reviewed-by:
Lu Baolu <baolu.lu@linux.intel.com> Signed-off-by:
Jason Gunthorpe <jgg@nvidia.com>
Loading
Please sign in to comment