From: Nishanth Menon <nm@ti.com>
To: Andrew Davis <afd@ti.com>
Cc: Dhruva Gole <d-gole@ti.com>,
Vignesh Raghavendra <vigneshr@ti.com>,
Tero Kristo <kristo@kernel.org>, Rob Herring <robh+dt@kernel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
Conor Dooley <conor+dt@kernel.org>,
<linux-arm-kernel@lists.infradead.org>,
<devicetree@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 10/13] arm64: dts: ti: k3-j7200: Enable GPIO nodes at the board level
Date: Mon, 7 Aug 2023 10:42:07 -0500 [thread overview]
Message-ID: <20230807154207.7eho6er55revipjo@shuffling> (raw)
In-Reply-To: <1b3366b0-e3a4-3609-9e25-7b880d2fe656@ti.com>
On 10:28-20230807, Andrew Davis wrote:
> On 8/7/23 12:38 AM, Dhruva Gole wrote:
> > Andrew,
> >
> > On 03/08/23 02:23, Andrew Davis wrote:
> > > GPIO nodes defined in the top-level J7200 SoC dtsi files are incomplete
> > > and may not be functional unless they are extended with pinmux and
> > > device information.
> > >
> > > Disable the GPIO nodes in the dtsi files and only enable the ones that
> > > are actually pinned out on a given board.
> > >
> > > Signed-off-by: Andrew Davis <afd@ti.com>
> > > ---
> > > .../boot/dts/ti/k3-j7200-common-proc-board.dts | 18 ++++--------------
> > > arch/arm64/boot/dts/ti/k3-j7200-main.dtsi | 4 ++++
> > > .../arm64/boot/dts/ti/k3-j7200-mcu-wakeup.dtsi | 2 ++
> > > 3 files changed, 10 insertions(+), 14 deletions(-)
> > >
> > > diff --git a/arch/arm64/boot/dts/ti/k3-j7200-common-proc-board.dts b/arch/arm64/boot/dts/ti/k3-j7200-common-proc-board.dts
> > > index dee9056f56051..4a5c4f36baeec 100644
> > > --- a/arch/arm64/boot/dts/ti/k3-j7200-common-proc-board.dts
> > > +++ b/arch/arm64/boot/dts/ti/k3-j7200-common-proc-board.dts
> > > @@ -240,27 +240,17 @@ &main_uart3 {
> > > pinctrl-0 = <&main_uart3_pins_default>;
> > > };
> > > -&main_gpio2 {
> > > - status = "disabled";
> > > -};
> > > -
> > > -&main_gpio4 {
> > > - status = "disabled";
> > > -};
> > > -
> > > -&main_gpio6 {
> > > - status = "disabled";
> > > +&main_gpio0 {
> > > + status = "okay";
> > > + /* default pins */
> >
> > Small question, where is the pmx for main_gpio0? What does "default pins"
> > refer to here? Where are they pinmuxed?
> >
>
> Good question, where is the pmx for main_gpio0? I don't know, it was
> never defined before either, we only are noticing this now as we are
> disabling by default instead of leaving an unfinished node enabled
> by default. (another benefit of this disabled by default scheme).
>
> What is really happening is GPIO nodes we tend to pinmux differently
> than normal device nodes. Their pinmux selections tends to be spread
> out in all the nodes that make use of these GPIO pins, not all together
> here in this node.
>
> For instance in this device we use one of the main_gpio0 pins as a
> GPIO toggled regulator, and we define the pinmux for it in that node
> (see vdd-sd-dv-default-pins).
>
> We can either define the rest of the pins not used elsewhere
> here, or we can consider GPIO an exception to the rule, I'd say
> the latter is fine for now.
GPIO pinmux are typically defined where they need - the only place where
they are explicitly called out in gpio is when they are meant to be used by
libgpio - typically in the case of dev boards.
Just drop the comments of /* default pins */ - that is just mis-leading.
--
Regards,
Nishanth Menon
Key (0xDDB5849D1736249D) / Fingerprint: F8A2 8693 54EB 8232 17A3 1A34 DDB5 849D 1736 249D
next prev parent reply other threads:[~2023-08-07 15:42 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-02 20:52 [PATCH 00/13] Another round of K3 DTSI disables Andrew Davis
2023-08-02 20:52 ` [PATCH 01/13] arm64: dts: ti: k3-j721e: Enable SDHCI nodes at the board level Andrew Davis
2023-08-07 5:22 ` Dhruva Gole
2023-08-02 20:52 ` [PATCH 02/13] arm64: dts: ti: k3-j7200: " Andrew Davis
2023-08-02 20:52 ` [PATCH 03/13] arm64: dts: ti: k3-j721s2: " Andrew Davis
2023-08-02 20:53 ` [PATCH 04/13] arm64: dts: ti: k3-am65: Enable OSPI " Andrew Davis
2023-08-07 6:16 ` Dhruva Gole
2023-08-07 15:18 ` Andrew Davis
2023-08-08 5:27 ` Jan Kiszka
2023-08-08 13:16 ` Andrew Davis
2023-08-02 20:53 ` [PATCH 05/13] arm64: dts: ti: k3-j721e: " Andrew Davis
2023-08-02 20:53 ` [PATCH 06/13] arm64: dts: ti: k3-j7200: " Andrew Davis
2023-08-07 5:19 ` Dhruva Gole
2023-08-02 20:53 ` [PATCH 07/13] arm64: dts: ti: k3-am64: " Andrew Davis
2023-08-07 5:18 ` Dhruva Gole
2023-08-02 20:53 ` [PATCH 08/13] arm64: dts: ti: k3-j721e: Enable GPIO " Andrew Davis
2023-08-07 5:34 ` Dhruva Gole
2023-08-02 20:53 ` [PATCH 09/13] arm64: dts: ti: k3-j721s2: " Andrew Davis
2023-08-07 5:34 ` Dhruva Gole
2023-08-02 20:53 ` [PATCH 10/13] arm64: dts: ti: k3-j7200: " Andrew Davis
2023-08-07 5:38 ` Dhruva Gole
2023-08-07 15:28 ` Andrew Davis
2023-08-07 15:42 ` Nishanth Menon [this message]
2023-08-07 16:16 ` Andrew Davis
2023-08-02 20:53 ` [PATCH 11/13] arm64: dts: ti: k3-j721e: Enable TSCADC " Andrew Davis
2023-08-02 20:53 ` [PATCH 12/13] arm64: dts: ti: k3-am65: " Andrew Davis
2023-08-07 5:51 ` Dhruva Gole
2023-08-07 15:34 ` Andrew Davis
2023-08-02 20:53 ` [PATCH 13/13] arm64: dts: ti: k3-am64: " Andrew Davis
2023-08-07 5:41 ` Dhruva Gole
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230807154207.7eho6er55revipjo@shuffling \
--to=nm@ti.com \
--cc=afd@ti.com \
--cc=conor+dt@kernel.org \
--cc=d-gole@ti.com \
--cc=devicetree@vger.kernel.org \
--cc=kristo@kernel.org \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=robh+dt@kernel.org \
--cc=vigneshr@ti.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).