Message ID | 20221216215819.1164973-4-marijn.suijten@somainline.org |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:e747:0:0:0:0:0 with SMTP id c7csp1221585wrn; Fri, 16 Dec 2022 14:07:15 -0800 (PST) X-Google-Smtp-Source: AA0mqf4Z4htvJ/BKSUPJCzrF3Lwn0wrsJnSTxzNsI2leE1s2pn6+6ZzaS3FnMYl0b1B/wGYdsMP6 X-Received: by 2002:a17:906:8d08:b0:7c1:700:1e2d with SMTP id rv8-20020a1709068d0800b007c107001e2dmr45561860ejc.20.1671228435265; Fri, 16 Dec 2022 14:07:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671228435; cv=none; d=google.com; s=arc-20160816; b=ycM9QW14HYm/hDtT0suYQUiS/Bh1HQBVVC6uId7fQJT7fFy8P1/YbTBpBXCC/Dd1lh xCRohV8Lq5mArwHKMGW0jvF1ELvb2U58vuKvyCieYKwIJm9Dlnlzre9dDXn9Je7MtsKk VY+oop6JQLe2dbexOUtzVhbzmE7uLYOzTe2M1voD3F9rjZ9X6nODs66FCmBeFngQwq6b YV9LfWbQCERvyA87bhmOlM0QMAx93ZiVSDX+apV4wf24x25kRlnn16swT6ngNYlklWnq C9VJVouKHCUZDF8g74guWf2RwRGLAU7ZO9ktzWZdAzxXcASp7k8bhnK9yuqwc1I65emZ 1Xuw== 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; bh=rwx6y6LnGSPhTsZwfM8NX7ylHXmpB7an31boyPCN704=; b=AXnzOcTuFESdiwiaH1rgbB7AXmE1Li/o++j+FfkJTV9K4jZ7pXNo1sZ+j8iwWzTqUh DcwRW5NSWtcTS4/nrNmZJcPGzHk6sA7W9woSXuLOsZyyYIevvH0c5iireedcNoJB3eQl CYDiLbFNmyZ29TDpxBF3/rTL1Jx6zffvV2ySiXbZ0NbIomj1gkToAGqNfcaf3Vv/Apuw 6J2yHs4vSsqK65Q4vd2+2e+T+kvTTcS+QA4/SwXhWZvUNPjnS4dxsboo9hmM0iLc3u38 nJSEnoDQmBTW0yuXSS5b6gw4aVXD7H35mQLusd5AHrH8mnnwxzEMlDH3WvpbNQuHQdIr Jorw== ARC-Authentication-Results: i=1; mx.google.com; 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 du19-20020a17090772d300b007986956bd8esi193234ejc.472.2022.12.16.14.06.50; Fri, 16 Dec 2022 14:07:15 -0800 (PST) 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; 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 S229941AbiLPWAY (ORCPT <rfc822;jeantsuru.cumc.mandola@gmail.com> + 99 others); Fri, 16 Dec 2022 17:00:24 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41848 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229820AbiLPWAL (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Fri, 16 Dec 2022 17:00:11 -0500 Received: from relay03.th.seeweb.it (relay03.th.seeweb.it [IPv6:2001:4b7a:2000:18::164]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0D15D17A94; Fri, 16 Dec 2022 14:00:06 -0800 (PST) Received: from localhost.localdomain (94-209-172-39.cable.dynamic.v4.ziggo.nl [94.209.172.39]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by m-r1.th.seeweb.it (Postfix) with ESMTPSA id 8CD3F2013B; Fri, 16 Dec 2022 23:00:04 +0100 (CET) From: Marijn Suijten <marijn.suijten@somainline.org> To: phone-devel@vger.kernel.org, Will Deacon <will@kernel.org>, Joerg Roedel <joro@8bytes.org>, Bjorn Andersson <andersson@kernel.org> Cc: ~postmarketos/upstreaming@lists.sr.ht, AngeloGioacchino Del Regno <angelogioacchino.delregno@somainline.org>, Konrad Dybcio <konrad.dybcio@somainline.org>, Martin Botka <martin.botka@somainline.org>, Jami Kettunen <jami.kettunen@somainline.org>, Marijn Suijten <marijn.suijten@somainline.org>, Lux Aliaga <they@mint.lgbt>, Robin Murphy <robin.murphy@arm.com>, Rob Herring <robh+dt@kernel.org>, Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>, Andy Gross <agross@kernel.org>, Konrad Dybcio <konrad.dybcio@linaro.org>, Dmitry Baryshkov <dmitry.baryshkov@linaro.org>, Thierry Reding <treding@nvidia.com>, Melody Olvera <quic_molvera@quicinc.com>, Greg Kroah-Hartman <gregkh@linuxfoundation.org>, Bhupesh Sharma <bhupesh.sharma@linaro.org>, Douglas Anderson <dianders@chromium.org>, linux-arm-kernel@lists.infradead.org, iommu@lists.linux.dev, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org Subject: [PATCH v4 3/4] arm64: dts: qcom: sm6125: Add apps_smmu with streamID to SDHCI 1/2 nodes Date: Fri, 16 Dec 2022 22:58:18 +0100 Message-Id: <20221216215819.1164973-4-marijn.suijten@somainline.org> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20221216215819.1164973-1-marijn.suijten@somainline.org> References: <20221216215819.1164973-1-marijn.suijten@somainline.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS 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?1752410027848186112?= X-GMAIL-MSGID: =?utf-8?q?1752410027848186112?= |
Series |
arm64: dts: qcom: sm6125: Enable APPS SMMU
|
|
Commit Message
Marijn Suijten
Dec. 16, 2022, 9:58 p.m. UTC
When enabling the APPS SMMU the mainline driver reconfigures the SMMU
from its bootloader configuration, loosing the stream mapping for (among
which) the SDHCI hardware and breaking its ADMA feature. This feature
can be disabled with:
sdhci.debug_quirks=0x40
But it is of course desired to have this feature enabled and working
through the SMMU.
Signed-off-by: Marijn Suijten <marijn.suijten@somainline.org>
---
arch/arm64/boot/dts/qcom/sm6125.dtsi | 2 ++
1 file changed, 2 insertions(+)
Comments
On 16.12.2022 22:58, Marijn Suijten wrote: > When enabling the APPS SMMU the mainline driver reconfigures the SMMU > from its bootloader configuration, loosing the stream mapping for (among > which) the SDHCI hardware and breaking its ADMA feature. This feature > can be disabled with: > > sdhci.debug_quirks=0x40 > > But it is of course desired to have this feature enabled and working > through the SMMU. > > Signed-off-by: Marijn Suijten <marijn.suijten@somainline.org> > --- Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org> Konrad > arch/arm64/boot/dts/qcom/sm6125.dtsi | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/arch/arm64/boot/dts/qcom/sm6125.dtsi b/arch/arm64/boot/dts/qcom/sm6125.dtsi > index 347665c2067c..f560499cc0ca 100644 > --- a/arch/arm64/boot/dts/qcom/sm6125.dtsi > +++ b/arch/arm64/boot/dts/qcom/sm6125.dtsi > @@ -468,6 +468,7 @@ sdhc_1: mmc@4744000 { > <&gcc GCC_SDCC1_APPS_CLK>, > <&xo_board>; > clock-names = "iface", "core", "xo"; > + iommus = <&apps_smmu 0x160 0>; > > power-domains = <&rpmpd SM6125_VDDCX>; > > @@ -494,6 +495,7 @@ sdhc_2: mmc@4784000 { > <&gcc GCC_SDCC2_APPS_CLK>, > <&xo_board>; > clock-names = "iface", "core", "xo"; > + iommus = <&apps_smmu 0x180 0>; > > pinctrl-0 = <&sdc2_on_state>; > pinctrl-1 = <&sdc2_off_state>;
On 2022-12-16 22:58:18, Marijn Suijten wrote: > When enabling the APPS SMMU the mainline driver reconfigures the SMMU > from its bootloader configuration, loosing the stream mapping for (among > which) the SDHCI hardware and breaking its ADMA feature. This feature > can be disabled with: > > sdhci.debug_quirks=0x40 > > But it is of course desired to have this feature enabled and working > through the SMMU. > > Signed-off-by: Marijn Suijten <marijn.suijten@somainline.org> > --- > arch/arm64/boot/dts/qcom/sm6125.dtsi | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/arch/arm64/boot/dts/qcom/sm6125.dtsi b/arch/arm64/boot/dts/qcom/sm6125.dtsi > index 347665c2067c..f560499cc0ca 100644 > --- a/arch/arm64/boot/dts/qcom/sm6125.dtsi > +++ b/arch/arm64/boot/dts/qcom/sm6125.dtsi > @@ -468,6 +468,7 @@ sdhc_1: mmc@4744000 { > <&gcc GCC_SDCC1_APPS_CLK>, > <&xo_board>; > clock-names = "iface", "core", "xo"; > + iommus = <&apps_smmu 0x160 0>; I'll make the mask 0x0 (same below) in the next revision, please do not apply this patch. - Marijn > power-domains = <&rpmpd SM6125_VDDCX>; > > @@ -494,6 +495,7 @@ sdhc_2: mmc@4784000 { > <&gcc GCC_SDCC2_APPS_CLK>, > <&xo_board>; > clock-names = "iface", "core", "xo"; > + iommus = <&apps_smmu 0x180 0>; > > pinctrl-0 = <&sdc2_on_state>; > pinctrl-1 = <&sdc2_off_state>; > -- > 2.39.0 >
On Fri, Dec 16 2022 at 10:58:18 PM +01:00:00, Marijn Suijten <marijn.suijten@somainline.org> wrote: > When enabling the APPS SMMU the mainline driver reconfigures the SMMU > from its bootloader configuration, loosing the stream mapping for > (among > which) the SDHCI hardware and breaking its ADMA feature. This feature > can be disabled with: > > sdhci.debug_quirks=0x40 > > But it is of course desired to have this feature enabled and working > through the SMMU. > > Signed-off-by: Marijn Suijten <marijn.suijten@somainline.org> > --- > arch/arm64/boot/dts/qcom/sm6125.dtsi | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/arch/arm64/boot/dts/qcom/sm6125.dtsi > b/arch/arm64/boot/dts/qcom/sm6125.dtsi > index 347665c2067c..f560499cc0ca 100644 > --- a/arch/arm64/boot/dts/qcom/sm6125.dtsi > +++ b/arch/arm64/boot/dts/qcom/sm6125.dtsi > @@ -468,6 +468,7 @@ sdhc_1: mmc@4744000 { > <&gcc GCC_SDCC1_APPS_CLK>, > <&xo_board>; > clock-names = "iface", "core", "xo"; > + iommus = <&apps_smmu 0x160 0>; > > power-domains = <&rpmpd SM6125_VDDCX>; > > @@ -494,6 +495,7 @@ sdhc_2: mmc@4784000 { > <&gcc GCC_SDCC2_APPS_CLK>, > <&xo_board>; > clock-names = "iface", "core", "xo"; > + iommus = <&apps_smmu 0x180 0>; > > pinctrl-0 = <&sdc2_on_state>; > pinctrl-1 = <&sdc2_off_state>; > -- > 2.39.0 > With 0x0 as mask Reviewed-by: Martin Botka <martin.botka@somainline.org> -Martin
diff --git a/arch/arm64/boot/dts/qcom/sm6125.dtsi b/arch/arm64/boot/dts/qcom/sm6125.dtsi index 347665c2067c..f560499cc0ca 100644 --- a/arch/arm64/boot/dts/qcom/sm6125.dtsi +++ b/arch/arm64/boot/dts/qcom/sm6125.dtsi @@ -468,6 +468,7 @@ sdhc_1: mmc@4744000 { <&gcc GCC_SDCC1_APPS_CLK>, <&xo_board>; clock-names = "iface", "core", "xo"; + iommus = <&apps_smmu 0x160 0>; power-domains = <&rpmpd SM6125_VDDCX>; @@ -494,6 +495,7 @@ sdhc_2: mmc@4784000 { <&gcc GCC_SDCC2_APPS_CLK>, <&xo_board>; clock-names = "iface", "core", "xo"; + iommus = <&apps_smmu 0x180 0>; pinctrl-0 = <&sdc2_on_state>; pinctrl-1 = <&sdc2_off_state>;