Message ID | 20230411125910.401075-8-brgl@bgdev.pl |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp2573255vqo; Tue, 11 Apr 2023 06:25:43 -0700 (PDT) X-Google-Smtp-Source: AKy350Zg+PchZskjPsF4pFTe+ve0N20QIJl3u3oM5MlqPcAaNzEwWQukMLKpA+IGpowqUjoTAPeZ X-Received: by 2002:a05:6402:31ea:b0:504:7aaa:275e with SMTP id dy10-20020a05640231ea00b005047aaa275emr9052409edb.41.1681219543401; Tue, 11 Apr 2023 06:25:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681219543; cv=none; d=google.com; s=arc-20160816; b=vbBqrn0+tvLtGcMtlZwqhNfAUJJo0igibRNEsBjaujl7yPBVijDlzmBN6uX5s4x/1t Dvg0N2qwonyHt4H8GWFoOv8SRBtPL8QgiykQsdOqUSUQay9UG9IkF4ydDQj6T0AHf8Vx 8QXKP6V/KQGmaS30md0HCWGplRQyr7czlfya+Q3PEXfSwGQ9UC5U2aYptfbMhWwng2B3 jQpt9fSF2Fz8EWoTaapZfTbKg2c7JDUuX7UI7Ng2CQdhZGw5nS+VmWq6zIrMhMrtRNY6 JOz9UuAnhvOtoiX514qYrZHZ70BG/a69Tn7o5bQ5Imtv17JOuUUHTFXnKZPHqlghZiac jliA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=ti2ysbW8Cc+oBh8xPSaQGRD6NB9f1GZWXnz69twS12o=; b=xMrmyF7CQB95/Deuu8BmxCJjXF+ilOp96I7o9gdbtThT8HfhVqhjPcXMYpLhdNzG9T IT5Cx5f70OVz/KO0iJ/7PWCqnP/a686/+548yihIOViXNxQOzCtxrRlhpLolFdEx7hsx xMaadUr6uCupFn9LhCZR4b2e+DaBatmOeOJrh1ntGYeYDqJXpPfG7iGUTI1plo2WvP6j d/wNv7kEzxj1WKKRd/HVFaEiprIrVhpldztnHZfnsoohJy1prS4PX56bG8/6l4z35NVV dxPrQ8YMWP98gD5/wtHyZ9WPZNuuraL8yEwp0FG6dJK2b2MTYf/aFaNnJCtU9+I2LM3h SxpA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bgdev-pl.20210112.gappssmtp.com header.s=20210112 header.b=OcPBHkjT; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ay25-20020a056402203900b00504aeb5999fsi3595048edb.535.2023.04.11.06.24.11; Tue, 11 Apr 2023 06:25:43 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@bgdev-pl.20210112.gappssmtp.com header.s=20210112 header.b=OcPBHkjT; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230324AbjDKNAC (ORCPT <rfc822;leviz.kernel.dev@gmail.com> + 99 others); Tue, 11 Apr 2023 09:00:02 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54430 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230205AbjDKM7h (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Tue, 11 Apr 2023 08:59:37 -0400 Received: from mail-wm1-x32c.google.com (mail-wm1-x32c.google.com [IPv6:2a00:1450:4864:20::32c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 355C3524C for <linux-kernel@vger.kernel.org>; Tue, 11 Apr 2023 05:59:23 -0700 (PDT) Received: by mail-wm1-x32c.google.com with SMTP id v14-20020a05600c470e00b003f06520825fso9529889wmo.0 for <linux-kernel@vger.kernel.org>; Tue, 11 Apr 2023 05:59:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20210112.gappssmtp.com; s=20210112; t=1681217962; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=ti2ysbW8Cc+oBh8xPSaQGRD6NB9f1GZWXnz69twS12o=; b=OcPBHkjTTSWddEDKyoUb2+Rw1AzfeC+W1Z4KEsw+L9fguKR4yDvpigeQSdoc4A4+HQ VVMrOqsX63Ff5/4h3UHRyc22kAmZugXh1CUgBkKmGFMSFlqcvDSAP20oZW/aXMwW1FEN 1F5AgwZ3dEsz7OLIr24DceU49mjUodZkXHjERTF67qXS/0MyT6thWsi23DEa6QbFyKL2 F8Oe3Nzf+USVMvY71bwaeI3Bj+a8LLmUdbuzH4Po2C1l/bf+k0DYolNItPadZpw70aJf JGjw+TNmlEZjB/VG94rJRw45W9drqYB1WbFeatRLbwF1zVLypvmKwqYKdtx5iOQaDmKn YcHw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1681217962; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ti2ysbW8Cc+oBh8xPSaQGRD6NB9f1GZWXnz69twS12o=; b=3v0ZLnjuiLf9xoiyNOTyociQO+83p4xhzUJEtFvCkNVE87KzUZ3JAg8bfPGMLPU6br ijO6AvUB1zWGTFHsltN5UTej/Eose3AOwA0Zr7C81Ttnh6d6UpWdNT/XJzENA/nPiyIh WIGuMiOaD33kMpkbz/Xnc8UGyi84Sg9LBfkgd4zPEsbmas6OymMDryLJEsh61hrzpRTO q4fW6nIRIeiIZu1gIAc9fAmld1RAmjYOJBCw43NA9QFI1L/eu93V3+5JlKQh4L4DhcQz +T0XRW1z7nXQ1Dq8q2UVB7o4c/RntFQYlsF9n3wamgEklvftcgvKim7M0Fv4gCiW4vkc 0oAQ== X-Gm-Message-State: AAQBX9dwuH9wr4XcDU+TFmWSD0H/9FmE1h+J9E3eDquHR3oHkvMuM+uz 0uNQEgjXA760yM4GA/GHYtbfNQ== X-Received: by 2002:a7b:c354:0:b0:3ed:301c:375c with SMTP id l20-20020a7bc354000000b003ed301c375cmr7357343wmj.21.1681217962443; Tue, 11 Apr 2023 05:59:22 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:a099:fc1d:c99a:bfc3]) by smtp.gmail.com with ESMTPSA id e24-20020a05600c219800b003eae73f0fc1sm16944591wme.18.2023.04.11.05.59.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Apr 2023 05:59:22 -0700 (PDT) From: Bartosz Golaszewski <brgl@bgdev.pl> To: Bjorn Andersson <andersson@kernel.org>, Andy Gross <agross@kernel.org>, Konrad Dybcio <konrad.dybcio@linaro.org>, Michael Turquette <mturquette@baylibre.com>, Stephen Boyd <sboyd@kernel.org>, Rob Herring <robh+dt@kernel.org>, Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>, Will Deacon <will@kernel.org>, Robin Murphy <robin.murphy@arm.com>, Joerg Roedel <joro@8bytes.org>, Catalin Marinas <catalin.marinas@arm.com>, Arnd Bergmann <arnd@arndb.de> Cc: linux-arm-msm@vger.kernel.org, linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, iommu@lists.linux.dev, Bartosz Golaszewski <bartosz.golaszewski@linaro.org> Subject: [PATCH v3 7/7] arm64: dts: qcom: sa8775p: add the GPU IOMMU node Date: Tue, 11 Apr 2023 14:59:10 +0200 Message-Id: <20230411125910.401075-8-brgl@bgdev.pl> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20230411125910.401075-1-brgl@bgdev.pl> References: <20230411125910.401075-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=0.0 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_NONE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1762886463711011098?= X-GMAIL-MSGID: =?utf-8?q?1762886463711011098?= |
Series |
arm64: dts: qcom: sa8775p: add more IOMMUs
|
|
Commit Message
Bartosz Golaszewski
April 11, 2023, 12:59 p.m. UTC
From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> Add the Adreno GPU IOMMU for sa8775p-based platforms. Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> --- arch/arm64/boot/dts/qcom/sa8775p.dtsi | 37 +++++++++++++++++++++++++++ 1 file changed, 37 insertions(+)
Comments
On 11.04.2023 14:59, Bartosz Golaszewski wrote: > From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> > > Add the Adreno GPU IOMMU for sa8775p-based platforms. > > Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> > --- > arch/arm64/boot/dts/qcom/sa8775p.dtsi | 37 +++++++++++++++++++++++++++ > 1 file changed, 37 insertions(+) > > diff --git a/arch/arm64/boot/dts/qcom/sa8775p.dtsi b/arch/arm64/boot/dts/qcom/sa8775p.dtsi > index 191b510b5a1a..11f3d80dd869 100644 > --- a/arch/arm64/boot/dts/qcom/sa8775p.dtsi > +++ b/arch/arm64/boot/dts/qcom/sa8775p.dtsi > @@ -7,6 +7,7 @@ > #include <dt-bindings/interrupt-controller/arm-gic.h> > #include <dt-bindings/clock/qcom,rpmh.h> > #include <dt-bindings/clock/qcom,sa8775p-gcc.h> > +#include <dt-bindings/clock/qcom,sa8775p-gpucc.h> > #include <dt-bindings/interconnect/qcom,sa8775p-rpmh.h> > #include <dt-bindings/power/qcom-rpmpd.h> > #include <dt-bindings/soc/qcom,rpmh-rsc.h> > @@ -605,6 +606,42 @@ gpucc: clock-controller@3d90000 { > #power-domain-cells = <1>; > }; > > + adreno_smmu: iommu@3da0000 { > + compatible = "qcom,sa8775p-smmu-500", "qcom,adreno-smmu", > + "arm,mmu-500"; Err.. does it even boot like this? You dropped the qcom,smmu-500 compatible which means it's getting bound to the generic SMMU driver (without QC quirks). If that was a mistake, you should have had all 4 "qcom,sa8775p-smmu-500", qcom,adreno-smmu, "qcom,smmu-500", "arm,mmu-500" Without falling into the qc-specific codepaths, the Adreno compat does nothing. Konrad > + reg = <0x0 0x03da0000 0x0 0x20000>; > + #iommu-cells = <2>; > + #global-interrupts = <2>; > + dma-coherent; > + power-domains = <&gpucc GPU_CC_CX_GDSC>; > + clocks = <&gcc GCC_GPU_MEMNOC_GFX_CLK>, > + <&gcc GCC_GPU_SNOC_DVM_GFX_CLK>, > + <&gpucc GPU_CC_AHB_CLK>, > + <&gpucc GPU_CC_HLOS1_VOTE_GPU_SMMU_CLK>, > + <&gpucc GPU_CC_CX_GMU_CLK>, > + <&gpucc GPU_CC_HUB_CX_INT_CLK>, > + <&gpucc GPU_CC_HUB_AON_CLK>; > + clock-names = "gcc_gpu_memnoc_gfx_clk", > + "gcc_gpu_snoc_dvm_gfx_clk", > + "gpu_cc_ahb_clk", > + "gpu_cc_hlos1_vote_gpu_smmu_clk", > + "gpu_cc_cx_gmu_clk", > + "gpu_cc_hub_cx_int_clk", > + "gpu_cc_hub_aon_clk"; > + interrupts = <GIC_SPI 673 IRQ_TYPE_LEVEL_HIGH>, > + <GIC_SPI 674 IRQ_TYPE_LEVEL_HIGH>, > + <GIC_SPI 678 IRQ_TYPE_LEVEL_HIGH>, > + <GIC_SPI 679 IRQ_TYPE_LEVEL_HIGH>, > + <GIC_SPI 680 IRQ_TYPE_LEVEL_HIGH>, > + <GIC_SPI 681 IRQ_TYPE_LEVEL_HIGH>, > + <GIC_SPI 682 IRQ_TYPE_LEVEL_HIGH>, > + <GIC_SPI 683 IRQ_TYPE_LEVEL_HIGH>, > + <GIC_SPI 684 IRQ_TYPE_LEVEL_HIGH>, > + <GIC_SPI 685 IRQ_TYPE_LEVEL_HIGH>, > + <GIC_SPI 686 IRQ_TYPE_LEVEL_HIGH>, > + <GIC_SPI 687 IRQ_TYPE_LEVEL_HIGH>; > + }; > + > pdc: interrupt-controller@b220000 { > compatible = "qcom,sa8775p-pdc", "qcom,pdc"; > reg = <0x0 0x0b220000 0x0 0x30000>,
On Tue, Apr 11, 2023 at 3:16 PM Konrad Dybcio <konrad.dybcio@linaro.org> wrote: > > > > On 11.04.2023 14:59, Bartosz Golaszewski wrote: > > From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> > > > > Add the Adreno GPU IOMMU for sa8775p-based platforms. > > > > Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> > > --- > > arch/arm64/boot/dts/qcom/sa8775p.dtsi | 37 +++++++++++++++++++++++++++ > > 1 file changed, 37 insertions(+) > > > > diff --git a/arch/arm64/boot/dts/qcom/sa8775p.dtsi b/arch/arm64/boot/dts/qcom/sa8775p.dtsi > > index 191b510b5a1a..11f3d80dd869 100644 > > --- a/arch/arm64/boot/dts/qcom/sa8775p.dtsi > > +++ b/arch/arm64/boot/dts/qcom/sa8775p.dtsi > > @@ -7,6 +7,7 @@ > > #include <dt-bindings/interrupt-controller/arm-gic.h> > > #include <dt-bindings/clock/qcom,rpmh.h> > > #include <dt-bindings/clock/qcom,sa8775p-gcc.h> > > +#include <dt-bindings/clock/qcom,sa8775p-gpucc.h> > > #include <dt-bindings/interconnect/qcom,sa8775p-rpmh.h> > > #include <dt-bindings/power/qcom-rpmpd.h> > > #include <dt-bindings/soc/qcom,rpmh-rsc.h> > > @@ -605,6 +606,42 @@ gpucc: clock-controller@3d90000 { > > #power-domain-cells = <1>; > > }; > > > > + adreno_smmu: iommu@3da0000 { > > + compatible = "qcom,sa8775p-smmu-500", "qcom,adreno-smmu", > > + "arm,mmu-500"; > Err.. does it even boot like this? You dropped the qcom,smmu-500 compatible > which means it's getting bound to the generic SMMU driver (without > QC quirks). If that was a mistake, you should have had all 4 > > "qcom,sa8775p-smmu-500", qcom,adreno-smmu, "qcom,smmu-500", "arm,mmu-500" > > Without falling into the qc-specific codepaths, the Adreno compat does > nothing. > I did that initially, then noticed dtbs_check fails because the existing adreno GPUs implementing "arm,smmu-500" expect three compatibles like in this commit. I did that and the driver still probed the same so I assumed all's good. You're right of course, the adreno impl is not being assigned without "qcom,smmu-500". Are the bindings wrong in this case and should it be something like the following? diff --git a/Documentation/devicetree/bindings/iommu/arm,smmu.yaml b/Documentation/devicetree/bindings/iommu/arm,smmu.yaml index d966dc65ce10..cd1b052a7242 100644 --- a/Documentation/devicetree/bindings/iommu/arm,smmu.yaml +++ b/Documentation/devicetree/bindings/iommu/arm,smmu.yaml @@ -84,6 +84,7 @@ properties: - qcom,sm8150-smmu-500 - qcom,sm8250-smmu-500 - const: qcom,adreno-smmu + - const: qcom,smmu-500 - const: arm,mmu-500 - description: Qcom Adreno GPUs implementing "arm,smmu-v2" items: Bartosz > Konrad > > + reg = <0x0 0x03da0000 0x0 0x20000>; > > + #iommu-cells = <2>; > > + #global-interrupts = <2>; > > + dma-coherent; > > + power-domains = <&gpucc GPU_CC_CX_GDSC>; > > + clocks = <&gcc GCC_GPU_MEMNOC_GFX_CLK>, > > + <&gcc GCC_GPU_SNOC_DVM_GFX_CLK>, > > + <&gpucc GPU_CC_AHB_CLK>, > > + <&gpucc GPU_CC_HLOS1_VOTE_GPU_SMMU_CLK>, > > + <&gpucc GPU_CC_CX_GMU_CLK>, > > + <&gpucc GPU_CC_HUB_CX_INT_CLK>, > > + <&gpucc GPU_CC_HUB_AON_CLK>; > > + clock-names = "gcc_gpu_memnoc_gfx_clk", > > + "gcc_gpu_snoc_dvm_gfx_clk", > > + "gpu_cc_ahb_clk", > > + "gpu_cc_hlos1_vote_gpu_smmu_clk", > > + "gpu_cc_cx_gmu_clk", > > + "gpu_cc_hub_cx_int_clk", > > + "gpu_cc_hub_aon_clk"; > > + interrupts = <GIC_SPI 673 IRQ_TYPE_LEVEL_HIGH>, > > + <GIC_SPI 674 IRQ_TYPE_LEVEL_HIGH>, > > + <GIC_SPI 678 IRQ_TYPE_LEVEL_HIGH>, > > + <GIC_SPI 679 IRQ_TYPE_LEVEL_HIGH>, > > + <GIC_SPI 680 IRQ_TYPE_LEVEL_HIGH>, > > + <GIC_SPI 681 IRQ_TYPE_LEVEL_HIGH>, > > + <GIC_SPI 682 IRQ_TYPE_LEVEL_HIGH>, > > + <GIC_SPI 683 IRQ_TYPE_LEVEL_HIGH>, > > + <GIC_SPI 684 IRQ_TYPE_LEVEL_HIGH>, > > + <GIC_SPI 685 IRQ_TYPE_LEVEL_HIGH>, > > + <GIC_SPI 686 IRQ_TYPE_LEVEL_HIGH>, > > + <GIC_SPI 687 IRQ_TYPE_LEVEL_HIGH>; > > + }; > > + > > pdc: interrupt-controller@b220000 { > > compatible = "qcom,sa8775p-pdc", "qcom,pdc"; > > reg = <0x0 0x0b220000 0x0 0x30000>,
On 11.04.2023 16:41, Bartosz Golaszewski wrote: > On Tue, Apr 11, 2023 at 3:16 PM Konrad Dybcio <konrad.dybcio@linaro.org> wrote: >> >> >> >> On 11.04.2023 14:59, Bartosz Golaszewski wrote: >>> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> >>> >>> Add the Adreno GPU IOMMU for sa8775p-based platforms. >>> >>> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> >>> --- >>> arch/arm64/boot/dts/qcom/sa8775p.dtsi | 37 +++++++++++++++++++++++++++ >>> 1 file changed, 37 insertions(+) >>> >>> diff --git a/arch/arm64/boot/dts/qcom/sa8775p.dtsi b/arch/arm64/boot/dts/qcom/sa8775p.dtsi >>> index 191b510b5a1a..11f3d80dd869 100644 >>> --- a/arch/arm64/boot/dts/qcom/sa8775p.dtsi >>> +++ b/arch/arm64/boot/dts/qcom/sa8775p.dtsi >>> @@ -7,6 +7,7 @@ >>> #include <dt-bindings/interrupt-controller/arm-gic.h> >>> #include <dt-bindings/clock/qcom,rpmh.h> >>> #include <dt-bindings/clock/qcom,sa8775p-gcc.h> >>> +#include <dt-bindings/clock/qcom,sa8775p-gpucc.h> >>> #include <dt-bindings/interconnect/qcom,sa8775p-rpmh.h> >>> #include <dt-bindings/power/qcom-rpmpd.h> >>> #include <dt-bindings/soc/qcom,rpmh-rsc.h> >>> @@ -605,6 +606,42 @@ gpucc: clock-controller@3d90000 { >>> #power-domain-cells = <1>; >>> }; >>> >>> + adreno_smmu: iommu@3da0000 { >>> + compatible = "qcom,sa8775p-smmu-500", "qcom,adreno-smmu", >>> + "arm,mmu-500"; >> Err.. does it even boot like this? You dropped the qcom,smmu-500 compatible >> which means it's getting bound to the generic SMMU driver (without >> QC quirks). If that was a mistake, you should have had all 4 >> >> "qcom,sa8775p-smmu-500", qcom,adreno-smmu, "qcom,smmu-500", "arm,mmu-500" >> >> Without falling into the qc-specific codepaths, the Adreno compat does >> nothing. >> > > I did that initially, then noticed dtbs_check fails because the > existing adreno GPUs implementing "arm,smmu-500" expect three > compatibles like in this commit. I did that and the driver still > probed the same so I assumed all's good. You're right of course, the > adreno impl is not being assigned without "qcom,smmu-500". Are the > bindings wrong in this case and should it be something like the > following? > > diff --git a/Documentation/devicetree/bindings/iommu/arm,smmu.yaml > b/Documentation/devicetree/bindings/iommu/arm,smmu.yaml > index d966dc65ce10..cd1b052a7242 100644 > --- a/Documentation/devicetree/bindings/iommu/arm,smmu.yaml > +++ b/Documentation/devicetree/bindings/iommu/arm,smmu.yaml > @@ -84,6 +84,7 @@ properties: > - qcom,sm8150-smmu-500 > - qcom,sm8250-smmu-500 > - const: qcom,adreno-smmu > + - const: qcom,smmu-500 > - const: arm,mmu-500 > - description: Qcom Adreno GPUs implementing "arm,smmu-v2" > items: > > Bartosz Check https://git.kernel.org/pub/scm/linux/kernel/git/will/linux.git/commit/?h=for-joerg/arm-smmu/bindings&id=5c3686616b1840b3143b227eb58fb1c1621d204e Konrad > >> Konrad >>> + reg = <0x0 0x03da0000 0x0 0x20000>; >>> + #iommu-cells = <2>; >>> + #global-interrupts = <2>; >>> + dma-coherent; >>> + power-domains = <&gpucc GPU_CC_CX_GDSC>; >>> + clocks = <&gcc GCC_GPU_MEMNOC_GFX_CLK>, >>> + <&gcc GCC_GPU_SNOC_DVM_GFX_CLK>, >>> + <&gpucc GPU_CC_AHB_CLK>, >>> + <&gpucc GPU_CC_HLOS1_VOTE_GPU_SMMU_CLK>, >>> + <&gpucc GPU_CC_CX_GMU_CLK>, >>> + <&gpucc GPU_CC_HUB_CX_INT_CLK>, >>> + <&gpucc GPU_CC_HUB_AON_CLK>; >>> + clock-names = "gcc_gpu_memnoc_gfx_clk", >>> + "gcc_gpu_snoc_dvm_gfx_clk", >>> + "gpu_cc_ahb_clk", >>> + "gpu_cc_hlos1_vote_gpu_smmu_clk", >>> + "gpu_cc_cx_gmu_clk", >>> + "gpu_cc_hub_cx_int_clk", >>> + "gpu_cc_hub_aon_clk"; >>> + interrupts = <GIC_SPI 673 IRQ_TYPE_LEVEL_HIGH>, >>> + <GIC_SPI 674 IRQ_TYPE_LEVEL_HIGH>, >>> + <GIC_SPI 678 IRQ_TYPE_LEVEL_HIGH>, >>> + <GIC_SPI 679 IRQ_TYPE_LEVEL_HIGH>, >>> + <GIC_SPI 680 IRQ_TYPE_LEVEL_HIGH>, >>> + <GIC_SPI 681 IRQ_TYPE_LEVEL_HIGH>, >>> + <GIC_SPI 682 IRQ_TYPE_LEVEL_HIGH>, >>> + <GIC_SPI 683 IRQ_TYPE_LEVEL_HIGH>, >>> + <GIC_SPI 684 IRQ_TYPE_LEVEL_HIGH>, >>> + <GIC_SPI 685 IRQ_TYPE_LEVEL_HIGH>, >>> + <GIC_SPI 686 IRQ_TYPE_LEVEL_HIGH>, >>> + <GIC_SPI 687 IRQ_TYPE_LEVEL_HIGH>; >>> + }; >>> + >>> pdc: interrupt-controller@b220000 { >>> compatible = "qcom,sa8775p-pdc", "qcom,pdc"; >>> reg = <0x0 0x0b220000 0x0 0x30000>,
diff --git a/arch/arm64/boot/dts/qcom/sa8775p.dtsi b/arch/arm64/boot/dts/qcom/sa8775p.dtsi index 191b510b5a1a..11f3d80dd869 100644 --- a/arch/arm64/boot/dts/qcom/sa8775p.dtsi +++ b/arch/arm64/boot/dts/qcom/sa8775p.dtsi @@ -7,6 +7,7 @@ #include <dt-bindings/interrupt-controller/arm-gic.h> #include <dt-bindings/clock/qcom,rpmh.h> #include <dt-bindings/clock/qcom,sa8775p-gcc.h> +#include <dt-bindings/clock/qcom,sa8775p-gpucc.h> #include <dt-bindings/interconnect/qcom,sa8775p-rpmh.h> #include <dt-bindings/power/qcom-rpmpd.h> #include <dt-bindings/soc/qcom,rpmh-rsc.h> @@ -605,6 +606,42 @@ gpucc: clock-controller@3d90000 { #power-domain-cells = <1>; }; + adreno_smmu: iommu@3da0000 { + compatible = "qcom,sa8775p-smmu-500", "qcom,adreno-smmu", + "arm,mmu-500"; + reg = <0x0 0x03da0000 0x0 0x20000>; + #iommu-cells = <2>; + #global-interrupts = <2>; + dma-coherent; + power-domains = <&gpucc GPU_CC_CX_GDSC>; + clocks = <&gcc GCC_GPU_MEMNOC_GFX_CLK>, + <&gcc GCC_GPU_SNOC_DVM_GFX_CLK>, + <&gpucc GPU_CC_AHB_CLK>, + <&gpucc GPU_CC_HLOS1_VOTE_GPU_SMMU_CLK>, + <&gpucc GPU_CC_CX_GMU_CLK>, + <&gpucc GPU_CC_HUB_CX_INT_CLK>, + <&gpucc GPU_CC_HUB_AON_CLK>; + clock-names = "gcc_gpu_memnoc_gfx_clk", + "gcc_gpu_snoc_dvm_gfx_clk", + "gpu_cc_ahb_clk", + "gpu_cc_hlos1_vote_gpu_smmu_clk", + "gpu_cc_cx_gmu_clk", + "gpu_cc_hub_cx_int_clk", + "gpu_cc_hub_aon_clk"; + interrupts = <GIC_SPI 673 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 674 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 678 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 679 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 680 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 681 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 682 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 683 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 684 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 685 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 686 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 687 IRQ_TYPE_LEVEL_HIGH>; + }; + pdc: interrupt-controller@b220000 { compatible = "qcom,sa8775p-pdc", "qcom,pdc"; reg = <0x0 0x0b220000 0x0 0x30000>,