iommufd: Support allocating nested parent domain
authorYi Liu <yi.l.liu@intel.com>
Thu, 28 Sep 2023 07:15:26 +0000 (00:15 -0700)
committerJason Gunthorpe <jgg@nvidia.com>
Tue, 10 Oct 2023 16:31:24 +0000 (13:31 -0300)
commit4ff542163397073f86eda484318d61980ff1031d
tree669d646d8406901948e805715ecf8f5041d2d9af
parent89d63875d80ea127280c60dd4cd101af1d9b6557
iommufd: Support allocating nested parent domain

Extend IOMMU_HWPT_ALLOC to allocate domains to be used as parent (stage-2)
in nested translation.

Add IOMMU_HWPT_ALLOC_NEST_PARENT to the uAPI.

Link: https://lore.kernel.org/r/20230928071528.26258-5-yi.l.liu@intel.com
Signed-off-by: Yi Liu <yi.l.liu@intel.com>
Reviewed-by: Kevin Tian <kevin.tian@intel.com>
Reviewed-by: Lu Baolu <baolu.lu@linux.intel.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
drivers/iommu/iommufd/hw_pagetable.c
include/uapi/linux/iommufd.h