From: Manuel Traut <manuel.traut@mt.com>
To: Wojciech Dubowik <Wojciech.Dubowik@mt.com>
Cc: linux-kernel@vger.kernel.org, Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Shawn Guo <shawnguo@kernel.org>,
Sascha Hauer <s.hauer@pengutronix.de>,
Pengutronix Kernel Team <kernel@pengutronix.de>,
Fabio Estevam <festevam@gmail.com>,
devicetree@vger.kernel.org, imx@lists.linux.dev,
linux-arm-kernel@lists.infradead.org,
Francesco Dolcini <francesco@dolcini.it>,
Philippe Schenker <philippe.schenker@impulsing.ch>,
stable@vger.kernel.org
Subject: Re: [PATCH v3] arm64: dts: imx8mm-verdin: Link reg_usdhc2_vqmmc to usdhc2
Date: Wed, 23 Apr 2025 08:00:47 +0200 [thread overview]
Message-ID: <aAiCDzWBG4APvF_H@mt.com> (raw)
In-Reply-To: <20250422140200.819405-1-Wojciech.Dubowik@mt.com>
On Tue, Apr 22, 2025 at 04:01:57PM +0200, Wojciech Dubowik wrote:
> Define vqmmc regulator-gpio for usdhc2 with vin-supply
> coming from LDO5.
>
> Without this definition LDO5 will be powered down, disabling
> SD card after bootup. This has been introduced in commit
> f5aab0438ef1 ("regulator: pca9450: Fix enable register for LDO5").
>
> Fixes: f5aab0438ef1 ("regulator: pca9450: Fix enable register for LDO5")
Tested on 6.15-rc2. SDCard stays present now. It also fixes the issue
for >=6.12.23
> Cc: stable@vger.kernel.org
> Signed-off-by: Wojciech Dubowik <Wojciech.Dubowik@mt.com>
Tested-by: Manuel Traut <manuel.traut@mt.com>
> ---
> v1 -> v2: https://lore.kernel.org/all/20250417112012.785420-1-Wojciech.Dubowik@mt.com/
> - define gpio regulator for LDO5 vin controlled by vselect signal
> v2 -> v3: https://lore.kernel.org/all/20250422130127.GA238494@francesco-nb/
> - specify vselect as gpio
> ---
> .../boot/dts/freescale/imx8mm-verdin.dtsi | 25 +++++++++++++++----
> 1 file changed, 20 insertions(+), 5 deletions(-)
>
> diff --git a/arch/arm64/boot/dts/freescale/imx8mm-verdin.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-verdin.dtsi
> index 7251ad3a0017..b46566f3ce20 100644
> --- a/arch/arm64/boot/dts/freescale/imx8mm-verdin.dtsi
> +++ b/arch/arm64/boot/dts/freescale/imx8mm-verdin.dtsi
> @@ -144,6 +144,19 @@ reg_usdhc2_vmmc: regulator-usdhc2 {
> startup-delay-us = <20000>;
> };
>
> + reg_usdhc2_vqmmc: regulator-usdhc2-vqmmc {
> + compatible = "regulator-gpio";
> + pinctrl-names = "default";
> + pinctrl-0 = <&pinctrl_usdhc2_vsel>;
> + gpios = <&gpio1 4 GPIO_ACTIVE_HIGH>;
> + regulator-max-microvolt = <3300000>;
> + regulator-min-microvolt = <1800000>;
> + states = <1800000 0x1>,
> + <3300000 0x0>;
> + regulator-name = "PMIC_USDHC_VSELECT";
> + vin-supply = <®_nvcc_sd>;
> + };
> +
> reserved-memory {
> #address-cells = <2>;
> #size-cells = <2>;
> @@ -269,7 +282,7 @@ &gpio1 {
> "SODIMM_19",
> "",
> "",
> - "",
> + "PMIC_USDHC_VSELECT",
> "",
> "",
> "",
> @@ -785,6 +798,7 @@ &usdhc2 {
> pinctrl-2 = <&pinctrl_usdhc2_200mhz>, <&pinctrl_usdhc2_cd>;
> pinctrl-3 = <&pinctrl_usdhc2_sleep>, <&pinctrl_usdhc2_cd_sleep>;
> vmmc-supply = <®_usdhc2_vmmc>;
> + vqmmc-supply = <®_usdhc2_vqmmc>;
> };
>
> &wdog1 {
> @@ -1206,13 +1220,17 @@ pinctrl_usdhc2_pwr_en: usdhc2pwrengrp {
> <MX8MM_IOMUXC_NAND_CLE_GPIO3_IO5 0x6>; /* SODIMM 76 */
> };
>
> + pinctrl_usdhc2_vsel: usdhc2vselgrp {
> + fsl,pins =
> + <MX8MM_IOMUXC_GPIO1_IO04_GPIO1_IO4 0x10>; /* PMIC_USDHC_VSELECT */
> + };
> +
> /*
> * Note: Due to ERR050080 we use discrete external on-module resistors pulling-up to the
> * on-module +V3.3_1.8_SD (LDO5) rail and explicitly disable the internal pull-ups here.
> */
> pinctrl_usdhc2: usdhc2grp {
> fsl,pins =
> - <MX8MM_IOMUXC_GPIO1_IO04_USDHC2_VSELECT 0x10>,
> <MX8MM_IOMUXC_SD2_CLK_USDHC2_CLK 0x90>, /* SODIMM 78 */
> <MX8MM_IOMUXC_SD2_CMD_USDHC2_CMD 0x90>, /* SODIMM 74 */
> <MX8MM_IOMUXC_SD2_DATA0_USDHC2_DATA0 0x90>, /* SODIMM 80 */
> @@ -1223,7 +1241,6 @@ pinctrl_usdhc2: usdhc2grp {
>
> pinctrl_usdhc2_100mhz: usdhc2-100mhzgrp {
> fsl,pins =
> - <MX8MM_IOMUXC_GPIO1_IO04_USDHC2_VSELECT 0x10>,
> <MX8MM_IOMUXC_SD2_CLK_USDHC2_CLK 0x94>,
> <MX8MM_IOMUXC_SD2_CMD_USDHC2_CMD 0x94>,
> <MX8MM_IOMUXC_SD2_DATA0_USDHC2_DATA0 0x94>,
> @@ -1234,7 +1251,6 @@ pinctrl_usdhc2_100mhz: usdhc2-100mhzgrp {
>
> pinctrl_usdhc2_200mhz: usdhc2-200mhzgrp {
> fsl,pins =
> - <MX8MM_IOMUXC_GPIO1_IO04_USDHC2_VSELECT 0x10>,
> <MX8MM_IOMUXC_SD2_CLK_USDHC2_CLK 0x96>,
> <MX8MM_IOMUXC_SD2_CMD_USDHC2_CMD 0x96>,
> <MX8MM_IOMUXC_SD2_DATA0_USDHC2_DATA0 0x96>,
> @@ -1246,7 +1262,6 @@ pinctrl_usdhc2_200mhz: usdhc2-200mhzgrp {
> /* Avoid backfeeding with removed card power */
> pinctrl_usdhc2_sleep: usdhc2slpgrp {
> fsl,pins =
> - <MX8MM_IOMUXC_GPIO1_IO04_USDHC2_VSELECT 0x0>,
> <MX8MM_IOMUXC_SD2_CLK_USDHC2_CLK 0x0>,
> <MX8MM_IOMUXC_SD2_CMD_USDHC2_CMD 0x0>,
> <MX8MM_IOMUXC_SD2_DATA0_USDHC2_DATA0 0x0>,
> --
> 2.47.2
>
next prev parent reply other threads:[~2025-04-23 6:03 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-22 14:01 [PATCH v3] arm64: dts: imx8mm-verdin: Link reg_usdhc2_vqmmc to usdhc2 Wojciech Dubowik
2025-04-23 6:00 ` Manuel Traut [this message]
2025-04-23 9:53 ` Francesco Dolcini
2025-04-23 10:16 ` Philippe Schenker
2025-04-23 10:21 ` Francesco Dolcini
2025-04-23 11:23 ` Philippe Schenker
2025-04-24 6:16 ` EXTERNAL - " Wojciech Dubowik
2025-04-24 7:21 ` Francesco Dolcini
2025-04-24 8:20 ` Philippe Schenker
2025-04-24 8:34 ` Francesco Dolcini
2025-04-24 9:24 ` Philippe Schenker
2025-04-24 8:07 ` Philippe Schenker
2025-04-24 8:26 ` Philippe Schenker
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=aAiCDzWBG4APvF_H@mt.com \
--to=manuel.traut@mt.com \
--cc=Wojciech.Dubowik@mt.com \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=festevam@gmail.com \
--cc=francesco@dolcini.it \
--cc=imx@lists.linux.dev \
--cc=kernel@pengutronix.de \
--cc=krzk+dt@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=philippe.schenker@impulsing.ch \
--cc=robh@kernel.org \
--cc=s.hauer@pengutronix.de \
--cc=shawnguo@kernel.org \
--cc=stable@vger.kernel.org \
/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).