Skip to content

iommu: Prevent oops in iommu_get() and while arch_iommu is in use

Sakari Ailus linux-omap 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 1 replyIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4omap iommu: Check existence of arch_iommuarch/arm/plat-omap/iommu.c+3 -00 replies
2/4omap iommu: Add module information to struct iommu_functionsarch/arm/plat-omap/include/plat/iommu.h+1 -00 replies
3/4omap2 iommu: Set module information in omap2_iommu_opsarch/arm/mach-omap2/iommu2.c+2 -00 replies
4/4omap iommu: Prevent iommu implementations from being unloaded while in usearch/arm/plat-omap/iommu.c+29 -20 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/4] iommu: Prevent oops in iommu_get() and while arch_iommu is in use

Hi,

[Resend: the patches were accidentally sent to linux-media instead. Apologies.]

This patchset is aimed to fix a problem in arch_iommu implementation references. When an actual arch_iommu implementation is not loaded while iommu_get() is being called results to a kernel oops, as well as removing an arch_iommu implementation which is in use.

This patchset fixes both issues.

The patchset assumes the arch_iommu is uninstalled at module unload time. Is this an acceptable requirement?

Serialisation of the access to arch_iommu is done using mutex called arch_iommu_mutex.

module_put() doesn't need to have the arch_iommu_mutex since when this gets called there won't be any users on the arch_iommu anyway.

Comments are welcome. :-)

Cheers,

Signature · 2 lines
Sakari Ailus
[email protected]