]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
arm64: dts: qcom: sc8280xp: Add PCIe IOMMU
authorNikita Travkin <nikita@trvn.ru>
Sat, 3 May 2025 10:39:29 +0000 (15:39 +0500)
committerBjorn Andersson <andersson@kernel.org>
Wed, 7 May 2025 05:26:35 +0000 (22:26 -0700)
sc8280xp has an SMMUv3 connected to PCIe which is normally controlled by
QHEE and is thus transparent to the OS. However if we boot Linux in EL2,
without QHEE, we need to manage this IOMMU ourselves. To make that
easier, and since the hardware actually exists, just not "usually"
managed by Linux, describe it in the dts as "reserved".

Signed-off-by: Nikita Travkin <nikita@trvn.ru>
Link: https://lore.kernel.org/r/20250503-sc-el2-overlays-v2-2-24e9b4572e15@trvn.ru
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
arch/arm64/boot/dts/qcom/sc8280xp.dtsi

index 35ef31d4ecf26125407bb64dd2de6e777a3400a3..27d21e1a2d50c6fc12f324ab2b4dfa4b99791b81 100644 (file)
                        };
                };
 
+               pcie_smmu: iommu@14f80000 {
+                       compatible = "arm,smmu-v3";
+                       reg = <0 0x14f80000 0 0x80000>;
+                       #iommu-cells = <1>;
+                       interrupts = <GIC_SPI 951 IRQ_TYPE_EDGE_RISING>,
+                                    <GIC_SPI 955 IRQ_TYPE_EDGE_RISING>,
+                                    <GIC_SPI 953 IRQ_TYPE_EDGE_RISING>;
+                       interrupt-names = "eventq",
+                                         "gerror",
+                                         "cmdq-sync";
+                       dma-coherent;
+                       status = "reserved"; /* Controlled by QHEE. */
+               };
+
                apps_smmu: iommu@15000000 {
                        compatible = "qcom,sc8280xp-smmu-500", "arm,mmu-500";
                        reg = <0 0x15000000 0 0x100000>;