Hi, Here's a series adding support for the IOMMU introduced in the Allwinner H6. The driver from Allwinner hints at more SoCs using it in the future (with more masters), so we can bet on that IOMMU becoming pretty much standard in new SoCs from Allwinner. One thing I wasn't really sure about was how to expose the statistics reported by the IOMMU PMU (TLB hit rates, latencies, and so on). The Allwinner driver exposes them through custom sysfs files, while they would be best represented through perf I guess? Anyway, I'm planning to support them later on. Let me know what you think, Maxime Changes from v2: - Rebased on 5.7 - Add dt bindings patch - Allow the identity domain to be allocated - Add an unlikely to the check on whether a PTE already exists in map - Remove locking and adjust the PT installation to use an atomic operation instead - Switch to iotlb_sync / flush_iotlb_all callback instead of flushing by ourselves. Changes from v1: - Add a patch to configure the IOMMU on the virtual DRM device - Rework the domain allocation / freeing - Remove the runtime_pm handling to power up the device and rely on refcounting - use map gfp argument for kmem cache allocation - Removed unused macros - Switched from BIT(0) to 1 for the page table entry valid flag to make it more obvious that it's over multiple bits. - Switch to module_initcall - Make accesses to the fwspec more consistant - Removed dev_info logs - Reworked invalidation / flushing - Allow for compilation with COMPILE_TEST Maxime Ripard (5): dt-bindings: iommu: Add Allwinner H6 IOMMU bindings dt-bindings: display: sun8i-mixer: Allow for an iommu property iommu: Add Allwinner H6 IOMMU driver arm64: dts: allwinner: h6: Add IOMMU drm/sun4i: mixer: Call of_dma_configure if there's an IOMMU Documentation/devicetree/bindings/display/allwinner,sun8i-a83t-de2-mixer.yaml | 3 +- Documentation/devicetree/bindings/iommu/allwinner,sun50i-h6-iommu.yaml | 61 ++++- arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 10 +- drivers/gpu/drm/sun4i/sun8i_mixer.c | 13 +- drivers/iommu/Kconfig | 9 +- drivers/iommu/Makefile | 1 +- drivers/iommu/sun50i-iommu.c | 1065 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++- 7 files changed, 1162 insertions(+) create mode 100644 Documentation/devicetree/bindings/iommu/allwinner,sun50i-h6-iommu.yaml create mode 100644 drivers/iommu/sun50i-iommu.c base-commit: 8f3d9f354286745c751374f5f1fcafee6b3f3136 -- git-series 0.9.1