public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Stefan Eichenberger <eichest@gmail.com>
To: marcel.ziswiler@toradex.com, trini@konsulko.com, nm@ti.com,
	francesco.dolcini@toradex.com, rogerq@kernel.org,
	stefan.eichenberger@toradex.com, andrejs.cainikovs@toradex.com
Cc: u-boot@lists.denx.de
Subject: [PATCH v1] arm: dts: verdin-am62: use gpio-hog for sleep moci
Date: Wed, 17 Apr 2024 10:39:21 +0200	[thread overview]
Message-ID: <20240417083921.13367-1-eichest@gmail.com> (raw)

From: Stefan Eichenberger <stefan.eichenberger@toradex.com>

In Linux, we allow sleep moci to be turned off when the carrier board
supports it and the system is in suspend. In U-Boot, however, we want
the sleep moci to be always on. So we use a gpio hog and disable the
regulator. This change is necessary because we switched to upstream
device tree files with commit c07bba7a2c7e ("verdin-am62: move verdin
am62 to OF_UPSTREAM"). A recent upstream patch removes the gpio hog from
the Linux device tree, so we need to add it to the u-boot dtsi. The
following patch will remove the gpio hog from the Linux device tree:
https://lore.kernel.org/linux-devicetree/20240301084901.16656-1-eichest@gmail.com/
The U-Boot patch can be applied without it and will not break the build.

Signed-off-by: Stefan Eichenberger <stefan.eichenberger@toradex.com>
---
 arch/arm/dts/k3-am625-verdin-wifi-dev-u-boot.dtsi | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)

diff --git a/arch/arm/dts/k3-am625-verdin-wifi-dev-u-boot.dtsi b/arch/arm/dts/k3-am625-verdin-wifi-dev-u-boot.dtsi
index 7fe7ae4154..9ecb305274 100644
--- a/arch/arm/dts/k3-am625-verdin-wifi-dev-u-boot.dtsi
+++ b/arch/arm/dts/k3-am625-verdin-wifi-dev-u-boot.dtsi
@@ -91,6 +91,14 @@
 
 &main_gpio0 {
 	bootph-all;
+
+	ctrl-sleep-moci-hog {
+		bootph-all;
+		gpio-hog;
+		gpios = <31 GPIO_ACTIVE_HIGH>;
+		line-name = "CTRL_SLEEP_MOCI#";
+		output-high;
+	};
 };
 
 /* On-module I2C - PMIC_I2C */
@@ -165,10 +173,6 @@
 	status = "disabled";
 };
 
-&verdin_ctrl_sleep_moci {
-	bootph-all;
-};
-
 /* Verdin UART_2 */
 &wkup_uart0 {
 	bootph-all;
-- 
2.40.1


             reply	other threads:[~2024-04-17 12:37 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-17  8:39 Stefan Eichenberger [this message]
2024-04-29 23:04 ` [PATCH v1] arm: dts: verdin-am62: use gpio-hog for sleep moci Tom Rini

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=20240417083921.13367-1-eichest@gmail.com \
    --to=eichest@gmail.com \
    --cc=andrejs.cainikovs@toradex.com \
    --cc=francesco.dolcini@toradex.com \
    --cc=marcel.ziswiler@toradex.com \
    --cc=nm@ti.com \
    --cc=rogerq@kernel.org \
    --cc=stefan.eichenberger@toradex.com \
    --cc=trini@konsulko.com \
    --cc=u-boot@lists.denx.de \
    /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