From: Jason Gunthorpe Date: Tue, 29 Nov 2022 00:34:32 +0000 (-0400) Subject: iommu: Remove IOMMU_CAP_INTR_REMAP X-Git-Tag: v6.3-rc1~103^2~7^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b062007c63eb4452f1122384e86d402531fb1d52;p=thirdparty%2Flinux.git iommu: Remove IOMMU_CAP_INTR_REMAP No iommu driver implements this any more, get rid of it. Link: https://lore.kernel.org/r/9-v3-3313bb5dd3a3+10f11-secure_msi_jgg@nvidia.com Tested-by: Matthew Rosato Reviewed-by: Kevin Tian Reviewed-by: Lu Baolu Signed-off-by: Jason Gunthorpe --- diff --git a/drivers/iommu/iommu.c b/drivers/iommu/iommu.c index 4c2199a493d84..834e6ecf3e519 100644 --- a/drivers/iommu/iommu.c +++ b/drivers/iommu/iommu.c @@ -1914,10 +1914,8 @@ bool iommu_group_has_isolated_msi(struct iommu_group *group) bool ret = true; mutex_lock(&group->mutex); - list_for_each_entry(group_dev, &group->devices, list) { - ret &= msi_device_has_isolated_msi(group_dev->dev) || - device_iommu_capable(group_dev->dev, IOMMU_CAP_INTR_REMAP); - } + list_for_each_entry(group_dev, &group->devices, list) + ret &= msi_device_has_isolated_msi(group_dev->dev); mutex_unlock(&group->mutex); return ret; } diff --git a/include/linux/iommu.h b/include/linux/iommu.h index 9b7a9fa5ad28d..933cc57bfc481 100644 --- a/include/linux/iommu.h +++ b/include/linux/iommu.h @@ -120,7 +120,6 @@ static inline bool iommu_is_dma_domain(struct iommu_domain *domain) enum iommu_cap { IOMMU_CAP_CACHE_COHERENCY, /* IOMMU_CACHE is supported */ - IOMMU_CAP_INTR_REMAP, /* IOMMU supports interrupt isolation */ IOMMU_CAP_NOEXEC, /* IOMMU_NOEXEC flag */ IOMMU_CAP_PRE_BOOT_PROTECTION, /* Firmware says it used the IOMMU for DMA protection and we should too */