diff options
author | Robin Murphy <robin.murphy@arm.com> | 2023-11-21 19:04:03 +0100 |
---|---|---|
committer | Joerg Roedel <jroedel@suse.de> | 2023-11-27 11:03:16 +0100 |
commit | e7080665c977ea1aafb8547a9c7bd08b199311d6 (patch) | |
tree | b50a0af095751dbc9e46f1e7c240cac8c9d94e91 /drivers/iommu/mtk_iommu_v1.c | |
parent | iommu: Retire bus ops (diff) | |
download | linux-e7080665c977ea1aafb8547a9c7bd08b199311d6.tar.xz linux-e7080665c977ea1aafb8547a9c7bd08b199311d6.zip |
iommu: Clean up open-coded ownership checks
Some drivers already implement their own defence against the possibility
of being given someone else's device. Since this is now taken care of by
the core code (and via a slightly different path from the original
fwspec-based idea), let's clean them up.
Acked-by: Will Deacon <will@kernel.org>
Reviewed-by: Jason Gunthorpe <jgg@nvidia.com>
Reviewed-by: Jerry Snitselaar <jsnitsel@redhat.com>
Signed-off-by: Robin Murphy <robin.murphy@arm.com>
Link: https://lore.kernel.org/r/58a9879ce3f03562bb061e6714fe6efb554c3907.1700589539.git.robin.murphy@arm.com
Signed-off-by: Joerg Roedel <jroedel@suse.de>
Diffstat (limited to 'drivers/iommu/mtk_iommu_v1.c')
-rw-r--r-- | drivers/iommu/mtk_iommu_v1.c | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/iommu/mtk_iommu_v1.c b/drivers/iommu/mtk_iommu_v1.c index 67e044c1a7d9..25b41222abae 100644 --- a/drivers/iommu/mtk_iommu_v1.c +++ b/drivers/iommu/mtk_iommu_v1.c @@ -481,9 +481,6 @@ static struct iommu_device *mtk_iommu_v1_probe_device(struct device *dev) idx++; } - if (!fwspec || fwspec->ops != &mtk_iommu_v1_ops) - return ERR_PTR(-ENODEV); /* Not a iommu client device */ - data = dev_iommu_priv_get(dev); /* Link the consumer device with the smi-larb device(supplier) */ |