Message ID | 20240121-msm8976-dt-v2-4-7b186a02dc72@somainline.org |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel+bounces-32211-ouuuleilei=gmail.com@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7301:2bc4:b0:101:a8e8:374 with SMTP id hx4csp2263138dyb; Sun, 21 Jan 2024 14:34:15 -0800 (PST) X-Google-Smtp-Source: AGHT+IFTBPubbQKlM55tQtxD1ad1VO17c91+TRSr7xfT7eesIEuifNHW6fs/jhW3b/diZNi5Np8e X-Received: by 2002:a05:6e02:f81:b0:361:a9ae:d0d with SMTP id v1-20020a056e020f8100b00361a9ae0d0dmr4265076ilo.35.1705876455088; Sun, 21 Jan 2024 14:34:15 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1705876455; cv=pass; d=google.com; s=arc-20160816; b=PCqw/Vu90KaBHtPsGNRG+1nH/j55UeS1XFqJcO1ePT7yyKfP76CshYrEbYIXk8rC1L /QdZCPYBW2BQk3Uo1u5UDCOMRt1aF4AbA6MSPp+6jFhV9xkXkfnvycOVyCNgHvEHhbUS P/8YE6gcRArSDzY8pnI/96i+ltRTTSBjwzrXMl6M/uXFBFErEA+5xaHygdFKNm+MtBnC yZPY0fAro2C3dr7602VmfYrXz/1TPpY2+ZRxQgNaxyLMJsBHfbUoiMVnpgjj5HGQ9qpI 8ZohgtH9oOd6aC4ZTEGeMWrGwB43X2SfIPmcs7liazlh6SsvlQkvvKL8OAESsWZuCDsa Gwmg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :subject:date:from; bh=K7AMLWW+CEwxuL8dLr8lPHHnd1kJjcxtJjD2z+tkrlU=; fh=cIXbSO4AX1Qnl5qlb1ihZ3NJfL1FzL7RHuzbkbWyu6k=; b=ObML57fbqesGeFVi/rCDsobKS7UACjoCTXegHrnDyNHssS31YWrZJuBHu9CbaShHVO GE8hX4RwsDEHm0a2nzZ2SIn9TgEWCHGqnIDtSm4twkIGw8nqk8K5Ydwjqy9v18qCXKyG p8JU1tp8uy141dviV3Kd/IVrPyJaLFxPAh4uinZfpytr0RgI3pCzbDTA3C493uaGtcoC +m16JV+EJppawfFgc5ehFtQbZZty9fVWjewlPAmbPeU3GOir20wwu51ZUaiZXswF4ikD 96zU8uEMDCbhgZRIvbumMsUDeKp3xmvCdQbZIVDwZUT95tnssofzABuM3iaE2WY+E6H8 J9pQ== ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=somainline.org); spf=pass (google.com: domain of linux-kernel+bounces-32211-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-32211-ouuuleilei=gmail.com@vger.kernel.org" Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id u7-20020a170902e80700b001d7406078b6si2035758plg.210.2024.01.21.14.34.14 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 21 Jan 2024 14:34:15 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-32211-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=somainline.org); spf=pass (google.com: domain of linux-kernel+bounces-32211-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-32211-ouuuleilei=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id D0D1B281C0C for <ouuuleilei@gmail.com>; Sun, 21 Jan 2024 22:34:14 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 9C87539859; Sun, 21 Jan 2024 22:33:47 +0000 (UTC) Received: from relay02.th.seeweb.it (relay02.th.seeweb.it [5.144.164.163]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9BCCE38392 for <linux-kernel@vger.kernel.org>; Sun, 21 Jan 2024 22:33:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=5.144.164.163 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705876426; cv=none; b=purzPw8PAdtL1TlSe/B1sn/ltidMW6kZnKWI/7bky6Gu+HjecMoyiOsL3vqH0uJE/TYnydxiUPmfPe7//fLiTOxFF+t9ZDgR6Ju/8UeZ/n4X3eTPSlJ10uSol8/bbpGWBTyhW4ohbxKwXC92zKTcfy/l4fDcH/YK3PWZcx5hmT8= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705876426; c=relaxed/simple; bh=Ka0suA2f6Mht4+t9XWWJHrO4gwspsyTwEIQwdjMFPoc=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=m5ROh4ec+oxRymrZ1qku5+kgPhwiUcje/Hy+hqTvt+SiRBKkz+Da7RlDy/BTOHtgf2JgvKEhcWnglGE+gH7PpDgK3FFU12uE9tlihYStbVJXs1rNcvsjCEO4s7d4BNssH49vv4hJklbE0MqShVTJPKg5yolrjnCQCN7esiRViIQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=somainline.org; spf=pass smtp.mailfrom=somainline.org; arc=none smtp.client-ip=5.144.164.163 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=somainline.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=somainline.org Received: from Marijn-Arch-PC.localdomain (94-211-6-86.cable.dynamic.v4.ziggo.nl [94.211.6.86]) (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 7436720385; Sun, 21 Jan 2024 23:33:42 +0100 (CET) From: Marijn Suijten <marijn.suijten@somainline.org> Date: Sun, 21 Jan 2024 23:33:41 +0100 Subject: [PATCH v2 4/6] arm64: dts: qcom: msm8976: Declare and use SDC1 pins Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: <linux-kernel.vger.kernel.org> List-Subscribe: <mailto:linux-kernel+subscribe@vger.kernel.org> List-Unsubscribe: <mailto:linux-kernel+unsubscribe@vger.kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20240121-msm8976-dt-v2-4-7b186a02dc72@somainline.org> References: <20240121-msm8976-dt-v2-0-7b186a02dc72@somainline.org> In-Reply-To: <20240121-msm8976-dt-v2-0-7b186a02dc72@somainline.org> To: Bjorn Andersson <andersson@kernel.org>, Rob Herring <robh+dt@kernel.org>, Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>, Conor Dooley <conor+dt@kernel.org> Cc: ~postmarketos/upstreaming@lists.sr.ht, AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>, Luca Weiss <luca@z3ntu.xyz>, Adam Skladowski <a39.skl@gmail.com>, Konrad Dybcio <konrad.dybcio@linaro.org>, Martin Botka <martin.botka@somainline.org>, Jami Kettunen <jami.kettunen@somainline.org>, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Marijn Suijten <marijn.suijten@somainline.org> X-Mailer: b4 0.12.4 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1788741109607532720 X-GMAIL-MSGID: 1788741109607532720 |
Series |
arm64: dts: qcom: msm8956-loire: SDCard and USB support
|
|
Commit Message
Marijn Suijten
Jan. 21, 2024, 10:33 p.m. UTC
Add the pinctrl states for SDC1 and use them on sdhc_1.
Signed-off-by: Marijn Suijten <marijn.suijten@somainline.org>
---
arch/arm64/boot/dts/qcom/msm8976.dtsi | 55 +++++++++++++++++++++++++++++++++++
1 file changed, 55 insertions(+)
Comments
On 21.01.2024 23:33, Marijn Suijten wrote: > Add the pinctrl states for SDC1 and use them on sdhc_1. > > Signed-off-by: Marijn Suijten <marijn.suijten@somainline.org> > --- [...] > @@ -840,6 +890,11 @@ sdhc_1: mmc@7824900 { > <&gcc GCC_SDCC1_APPS_CLK>, > <&rpmcc RPM_SMD_XO_CLK_SRC>; > clock-names = "iface", "core", "xo"; > + > + pinctrl-names = "default", "sleep"; > + pinctrl-0 = <&sdc1_on_state>; > + pinctrl-1 = <&sdc1_off_state>; -names should go last Konrad
On 2024-02-06 19:58:50, Konrad Dybcio wrote: > On 21.01.2024 23:33, Marijn Suijten wrote: > > Add the pinctrl states for SDC1 and use them on sdhc_1. > > > > Signed-off-by: Marijn Suijten <marijn.suijten@somainline.org> > > --- > > [...] > > > > @@ -840,6 +890,11 @@ sdhc_1: mmc@7824900 { > > <&gcc GCC_SDCC1_APPS_CLK>, > > <&rpmcc RPM_SMD_XO_CLK_SRC>; > > clock-names = "iface", "core", "xo"; > > + > > + pinctrl-names = "default", "sleep"; > > + pinctrl-0 = <&sdc1_on_state>; > > + pinctrl-1 = <&sdc1_off_state>; > > -names should go last Per the cover letter: - Moved pinctrl-names before pinctrl-N (Konrad); You explicitly requested this in https://lore.kernel.org/linux-arm-msm/60a40ace-d4e9-df74-88f9-4354d80efaac@linaro.org/#t but we also backtracked on it somewhat for consistency with other -names, and the general state of this file. Maybe we should apply v1 of this specific patch? - Marijn
Il 06/02/24 23:36, Marijn Suijten ha scritto: > On 2024-02-06 19:58:50, Konrad Dybcio wrote: >> On 21.01.2024 23:33, Marijn Suijten wrote: >>> Add the pinctrl states for SDC1 and use them on sdhc_1. >>> >>> Signed-off-by: Marijn Suijten <marijn.suijten@somainline.org> >>> --- >> >> [...] >> >> >>> @@ -840,6 +890,11 @@ sdhc_1: mmc@7824900 { >>> <&gcc GCC_SDCC1_APPS_CLK>, >>> <&rpmcc RPM_SMD_XO_CLK_SRC>; >>> clock-names = "iface", "core", "xo"; >>> + >>> + pinctrl-names = "default", "sleep"; >>> + pinctrl-0 = <&sdc1_on_state>; >>> + pinctrl-1 = <&sdc1_off_state>; >> >> -names should go last > Konrad is technically correct as per [1] but, for consistency, since all of the other nodes in msm8976.dtsi are following that order for pinctrl, this version of the patch is correct. That, unless anyone wants to reorder everything in this file as per [1], which may or may not be worth the noise. [1]: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/devicetree/bindings/dts-coding-style.rst Regards, Angelo > Per the cover letter: > > - Moved pinctrl-names before pinctrl-N (Konrad); > > You explicitly requested this in https://lore.kernel.org/linux-arm-msm/60a40ace-d4e9-df74-88f9-4354d80efaac@linaro.org/#t > but we also backtracked on it somewhat for consistency with other -names, and the general state of this file. > > Maybe we should apply v1 of this specific patch? > > - Marijn
On 6.02.2024 23:36, Marijn Suijten wrote: > On 2024-02-06 19:58:50, Konrad Dybcio wrote: >> On 21.01.2024 23:33, Marijn Suijten wrote: >>> Add the pinctrl states for SDC1 and use them on sdhc_1. >>> >>> Signed-off-by: Marijn Suijten <marijn.suijten@somainline.org> >>> --- >> >> [...] >> >> >>> @@ -840,6 +890,11 @@ sdhc_1: mmc@7824900 { >>> <&gcc GCC_SDCC1_APPS_CLK>, >>> <&rpmcc RPM_SMD_XO_CLK_SRC>; >>> clock-names = "iface", "core", "xo"; >>> + >>> + pinctrl-names = "default", "sleep"; >>> + pinctrl-0 = <&sdc1_on_state>; >>> + pinctrl-1 = <&sdc1_off_state>; >> >> -names should go last > > Per the cover letter: > > - Moved pinctrl-names before pinctrl-N (Konrad); > > You explicitly requested this in https://lore.kernel.org/linux-arm-msm/60a40ace-d4e9-df74-88f9-4354d80efaac@linaro.org/#t > but we also backtracked on it somewhat for consistency with other -names, and the general state of this file. Agreed, but we made up our minds since 2022-12-15 ;) Konrad
diff --git a/arch/arm64/boot/dts/qcom/msm8976.dtsi b/arch/arm64/boot/dts/qcom/msm8976.dtsi index d2bb1ada361a..1d06f9b8a0f1 100644 --- a/arch/arm64/boot/dts/qcom/msm8976.dtsi +++ b/arch/arm64/boot/dts/qcom/msm8976.dtsi @@ -669,6 +669,56 @@ tlmm: pinctrl@1000000 { interrupt-controller; #interrupt-cells = <2>; + sdc1_off_state: sdc1-off-state { + clk-pins { + pins = "sdc1_clk"; + drive-strength = <2>; + bias-disable; + }; + + cmd-pins { + pins = "sdc1_cmd"; + drive-strength = <2>; + bias-pull-up; + }; + + data-pins { + pins = "sdc1_data"; + drive-strength = <2>; + bias-pull-up; + }; + + rclk-pins { + pins = "sdc1_rclk"; + bias-pull-down; + }; + }; + + sdc1_on_state: sdc1-on-state { + clk-pins { + pins = "sdc1_clk"; + drive-strength = <16>; + bias-disable; + }; + + cmd-pins { + pins = "sdc1_cmd"; + drive-strength = <10>; + bias-pull-up; + }; + + data-pins { + pins = "sdc1_data"; + drive-strength = <10>; + bias-pull-up; + }; + + rclk-pins { + pins = "sdc1_rclk"; + bias-pull-down; + }; + }; + spi1_default: spi0-default-state { spi-pins { pins = "gpio0", "gpio1", "gpio3"; @@ -840,6 +890,11 @@ sdhc_1: mmc@7824900 { <&gcc GCC_SDCC1_APPS_CLK>, <&rpmcc RPM_SMD_XO_CLK_SRC>; clock-names = "iface", "core", "xo"; + + pinctrl-names = "default", "sleep"; + pinctrl-0 = <&sdc1_on_state>; + pinctrl-1 = <&sdc1_off_state>; + status = "disabled"; };