iommu: Add iommu_group_has_isolated_msi()
authorJason Gunthorpe <jgg@nvidia.com>
Fri, 9 Dec 2022 17:23:08 +0000 (13:23 -0400)
committerJason Gunthorpe <jgg@nvidia.com>
Wed, 11 Jan 2023 20:27:17 +0000 (16:27 -0400)
commitefc30a8f15a7981737297f9e9c62fb814d74e268
tree1019afe595e6de5dfe75e44266321c0ce204af5b
parent17cde5e601b165174e8a433b550f84f362731164
iommu: Add iommu_group_has_isolated_msi()

Compute the isolated_msi over all the devices in the IOMMU group because
iommufd and vfio both need to know that the entire group is isolated
before granting access to it.

Link: https://lore.kernel.org/r/2-v3-3313bb5dd3a3+10f11-secure_msi_jgg@nvidia.com
Tested-by: Matthew Rosato <mjrosato@linux.ibm.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/iommu.c
include/linux/iommu.h