summaryrefslogtreecommitdiff
path: root/drivers/iommu/iommu.c
diff options
context:
space:
mode:
authorJason Gunthorpe <jgg@nvidia.com>2023-07-17 15:11:59 -0300
committerJason Gunthorpe <jgg@nvidia.com>2023-07-26 10:19:22 -0300
commit91a2e17e243f70e0aec29facf44946439fce9195 (patch)
tree01205c32857b718c706727b52267b4f2031b4dfd /drivers/iommu/iommu.c
parent3a3329a7f14a7a0a8c30a12c7ed9f1f77f8efaa1 (diff)
downloadlwn-91a2e17e243f70e0aec29facf44946439fce9195.tar.gz
lwn-91a2e17e243f70e0aec29facf44946439fce9195.zip
iommufd: Replace the hwpt->devices list with iommufd_group
The devices list was used as a simple way to avoid having per-group information. Now that this seems to be unavoidable, just commit to per-group information fully and remove the devices list from the HWPT. The iommufd_group stores the currently assigned HWPT for the entire group and we can manage the per-device attach/detach with a list in the iommufd_group. For destruction the flow is organized to make the following patches easier, the actual call to iommufd_object_destroy_user() is done at the top of the call chain without holding any locks. The HWPT to be destroyed is returned out from the locked region to make this possible. Later patches create locking that requires this. Link: https://lore.kernel.org/r/3-v8-6659224517ea+532-iommufd_alloc_jgg@nvidia.com Reviewed-by: Lu Baolu <baolu.lu@linux.intel.com> Reviewed-by: Kevin Tian <kevin.tian@intel.com> Tested-by: Nicolin Chen <nicolinc@nvidia.com> Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Diffstat (limited to 'drivers/iommu/iommu.c')
0 files changed, 0 insertions, 0 deletions