]> git.baikalelectronics.ru Git - kernel.git/commit
iommu: Statically set module owner
authorRobin Murphy <robin.murphy@arm.com>
Thu, 1 Apr 2021 13:56:25 +0000 (14:56 +0100)
committerJoerg Roedel <jroedel@suse.de>
Fri, 16 Apr 2021 15:19:04 +0000 (17:19 +0200)
commit5b4afd27e2612355c6f770636da8acd84586fe75
treedb60787936d90a2a97cc174e4af6c2d7d2aec5b3
parent7175c8fdbdf9278469683667b7ff5720fca71c7c
iommu: Statically set module owner

It happens that the 3 drivers which first supported being modular are
also ones which play games with their pgsize_bitmap, so have non-const
iommu_ops where dynamically setting the owner manages to work out OK.
However, it's less than ideal to force that upon all drivers which want
to be modular - like the new sprd-iommu driver which now has a potential
bug in that regard - so let's just statically set the module owner and
let ops remain const wherever possible.

Reviewed-by: Christoph Hellwig <hch@lst.de>
Acked-by: Will Deacon <will@kernel.org>
Signed-off-by: Robin Murphy <robin.murphy@arm.com>
Link: https://lore.kernel.org/r/31423b99ff609c3d4b291c701a7a7a810d9ce8dc.1617285386.git.robin.murphy@arm.com
Signed-off-by: Joerg Roedel <jroedel@suse.de>
drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c
drivers/iommu/arm/arm-smmu/arm-smmu.c
drivers/iommu/sprd-iommu.c
drivers/iommu/virtio-iommu.c
include/linux/iommu.h