From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Ahmad Fatoum <a.fatoum@pengutronix.de>
Cc: linux-arm-kernel@lists.infradead.org, imx@lists.linux.dev,
devicetree@vger.kernel.org, Rob Herring <robh+dt@kernel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
Shawn Guo <shawnguo@kernel.org>, Li Yang <leoyang.li@nxp.com>,
Marco Contenti <marco.c@variscite.com>,
Nate Drude <nate.d@variscite.com>,
FrancescoFerraro <francesco.f@variscite.com>,
Harshesh Valera <harshesh.v@variscite.com>,
Pengutronix Kernel Team <kernel@pengutronix.de>
Subject: Re: [PATCH v2 2/4] arm64: dts: freescale: Add support for the Variscite DART-MX8M-PLUS SoM
Date: Sat, 8 Jun 2024 19:18:33 +0300 [thread overview]
Message-ID: <20240608161833.GA13794@pendragon.ideasonboard.com> (raw)
In-Reply-To: <962e1d33-bc97-6bf8-b94d-581762dd6afa@pengutronix.de>
Hi Ahmad,
On Mon, Nov 27, 2023 at 06:58:31AM +0100, Ahmad Fatoum wrote:
> On 25.10.23 18:50, Laurent Pinchart wrote:
> > + reg_eqos_phy: regulator-eqos-phy {
> > + compatible = "regulator-fixed";
> > + regulator-name = "eqos-phy";
> > + regulator-min-microvolt = <3300000>;
> > + regulator-max-microvolt = <3300000>;
> > + gpio = <&gpio2 20 GPIO_ACTIVE_HIGH>;
> > + enable-active-high;
> > + regulator-always-on;
>
> Apparently, https://lore.kernel.org/all/20230721110345.3925719-1-m.felsch@pengutronix.de/
> didn't make it upstream. Perhaps you mentioning that you could use this would help get
> it unstuck? :)
I've replied to the series, but I agree with Rob, we need a better
solution. Someone will need to do the work :-)
> > +&eqos {
> > + pinctrl-names = "default";
> > + pinctrl-0 = <&pinctrl_eqos>;
> > + phy-mode = "rgmii";
> > + phy-handle = <ðphy0>;
> > + status = "okay";
> > +
> > + mdio {
> > + compatible = "snps,dwmac-mdio";
> > + #address-cells = <1>;
> > + #size-cells = <0>;
> > +
> > + ethphy0: ethernet-phy@0 {
> > + compatible = "ethernet-phy-ieee802.3-c22";
> > + reg = <0>;
> > + eee-broken-1000t;
> > + reset-gpios = <&gpio2 11 GPIO_ACTIVE_LOW>;
>
> Nitpick: Separate pinctrl entry for PHY GPIOs that's added to the PHY node?
> Makes it easier to check that all used signals are indeed muxed.
Fine with me.
> > + pmic@25 {
> > + compatible = "nxp,pca9450c";
> > + reg = <0x25>;
> > + pinctrl-names = "default";
> > + pinctrl-0 = <&pinctrl_pmic>;
> > + interrupt-parent = <&gpio1>;
> > + interrupts = <3 IRQ_TYPE_LEVEL_LOW>;
> > +
> > + regulators {
> > + BUCK1 {
> > + regulator-name = "BUCK1";
> > + regulator-min-microvolt = <600000>;
> > + regulator-max-microvolt = <2187500>;
>
> Nitpick: These may be the limits of what the BUCK can output, but they
> don't look like a safe operating range for the board. The Linux driver already
> has ranges hardcoded to cover what's possible by the hardware, so if you specify
> regulator range here, it should pertain to what the board and SoC are designed
> to handle.
I'll restrict that to [0.85V 0.95V], which are the typical voltages in
nominal and overdrive mode. If someone wants to lower it down to 0.805V
or increase it up to 1.0V, which are the minimum and maximum values
specified in the SoC's operating ranges, they can send a patch. I will
similarly restrict BUCK2 to [0.85V 1.0V].
BUCK4, BUCK5 and BUCK6 are more annoying. There is no public schematics,
and little information in the board's documentation.
For BUCK5, there's a mention in the board's documentation that indicates
it powers NVCC_SAI1_SAI5 with 1.8V by default before LDO4 takes over. It
is further set to 1.85V in U-Boot with a comment that states
/* Set BUCK5 voltage to 1.85V to fix Ethernet PHY reset */
if (var_detect_board_id() == BOARD_ID_DART)
pmic_reg_write(p, PCA9450_BUCK5OUT, 0x32);
I will restrict the range to [1.65V 1.95V] as documented in the i.MX8MP
operating ranges, and exclude the 3.3V operation mode given the
explanation in the board's documentation.
BUCK4 and BUCK6 are not mentioned anywhere, and not programmed by
U-Boot. I can only assume they're used at their 3.3V and 1.1V defaults.
BUCK6 likely powers NVCC_DRAM as in the EVK, which is consistent with
the board using LPDDR4. I'll set the output voltages to 3.3V and 1.1V
respectively.
LDOs are even worse. Only LDO4 is mentioned in the documentation (as
powering NVCC_SAI1_SAI5) and touched by the boot loader (set to 1.8V).
I'll modify the LDO4 range from the current 3.3V fixed value to [1.8V
3.3V], and won't touch the other LDOs.
> > +/* eMMC */
> > +&usdhc3 {
> > + pinctrl-names = "default", "state_100mhz", "state_200mhz";
> > + pinctrl-0 = <&pinctrl_usdhc3>;
> > + pinctrl-1 = <&pinctrl_usdhc3_100mhz>;
> > + pinctrl-2 = <&pinctrl_usdhc3_200mhz>;
> > + bus-width = <8>;
> > + non-removable;
>
> no-sd
> no-sdio
>
> may give you a tiny bit of speedup during probe, if you know that there will
> always be an eMMC here.
I'll add that, thanks.
> > + pinctrl_i2c1: i2c1grp {
> > + fsl,pins = <
> > + MX8MP_IOMUXC_I2C1_SCL__I2C1_SCL 0x400001c2
> > + MX8MP_IOMUXC_I2C1_SDA__I2C1_SDA 0x400001c2
> > + >;
> > + };
> > +
> > + pinctrl_i2c1_gpio: i2c1gpiogrp {
> > + fsl,pins = <
> > + MX8MP_IOMUXC_I2C1_SCL__GPIO5_IO14 0x1c2
> > + MX8MP_IOMUXC_I2C1_SDA__GPIO5_IO15 0x1c2
>
> This surprises me. I'd expect that the SION bit needs to be set for
> GPIO bus recovery.
I haven't tested GPIO bus recovery. I'll add the SION bits, as they make
sense.
--
Regards,
Laurent Pinchart
next prev parent reply other threads:[~2024-06-08 16:18 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-25 16:50 [PATCH v2 0/4] arm64: dts: freescale: Add Variscite i.MX8MP DART8MCustomBoard v2 Laurent Pinchart
2023-10-25 16:50 ` [PATCH v2 1/4] dt-bindings: arm: fsl: Add Variscite DT8MCustomBoard with DART MX8M-PLUS Laurent Pinchart
2023-10-25 16:50 ` [PATCH v2 2/4] arm64: dts: freescale: Add support for the Variscite DART-MX8M-PLUS SoM Laurent Pinchart
2023-11-27 5:58 ` Ahmad Fatoum
2023-11-27 6:13 ` Ahmad Fatoum
2024-06-08 16:50 ` Laurent Pinchart
2024-06-08 16:18 ` Laurent Pinchart [this message]
2023-10-25 16:50 ` [PATCH v2 3/4] arm64: dts: freescale: Add support for the Variscite i.MX8MP DART8MCustomBoard Laurent Pinchart
2023-11-27 6:07 ` Ahmad Fatoum
2024-06-08 16:49 ` Laurent Pinchart
2023-10-25 16:50 ` [PATCH v2 4/4] arm64: dts: freescale: Add panel overlay for Variscite DART Laurent Pinchart
2023-11-27 3:16 ` Shawn Guo
2024-06-08 17:43 ` Laurent Pinchart
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=20240608161833.GA13794@pendragon.ideasonboard.com \
--to=laurent.pinchart@ideasonboard.com \
--cc=a.fatoum@pengutronix.de \
--cc=devicetree@vger.kernel.org \
--cc=francesco.f@variscite.com \
--cc=harshesh.v@variscite.com \
--cc=imx@lists.linux.dev \
--cc=kernel@pengutronix.de \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=leoyang.li@nxp.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=marco.c@variscite.com \
--cc=nate.d@variscite.com \
--cc=robh+dt@kernel.org \
--cc=shawnguo@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