Devicetree
 help / color / mirror / Atom feed
* [PATCH v2 0/3] arm64: dts: imx8mm-var-dart: update SoM support
@ 2026-09-17 15:41 Stefano Radaelli
  2026-09-17 15:41 ` [PATCH v2 1/3] arm64: dts: imx8mm-var-dart: configure SAI3 synchronous RX mode Stefano Radaelli
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Stefano Radaelli @ 2026-09-17 15:41 UTC (permalink / raw)
  To: Frank Li, linux-kernel, devicetree, imx, linux-arm-kernel
  Cc: pierluigi.p, Stefano Radaelli, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Sascha Hauer, Pengutronix Kernel Team,
	Fabio Estevam

This series updates the Variscite DART-MX8M-MINI SoM device tree to
better reflect the currently supported hardware configuration.

The changes configure SAI3 in synchronous RX mode, add TPM support,
and increase the Ethernet PHY reset deassert delay to improve PHY
detection reliability.

v1->v2:
 - Add tpm pinctrl
 - Add comment on tpm reset line

Stefano Radaelli (3):
  arm64: dts: imx8mm-var-dart: configure SAI3 synchronous RX mode
  arm64: dts: imx8mm-var-dart: add TPM support
  arm64: dts: imx8mm-var-dart: increase PHY reset deassert delay

 .../boot/dts/freescale/imx8mm-var-dart.dtsi   | 21 ++++++++++++++++---
 1 file changed, 18 insertions(+), 3 deletions(-)


base-commit: 46d8fa682d263271f3ef7bf95166b124c19d6c62
-- 
2.47.3


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [PATCH v2 1/3] arm64: dts: imx8mm-var-dart: configure SAI3 synchronous RX mode
  2026-09-17 15:41 [PATCH v2 0/3] arm64: dts: imx8mm-var-dart: update SoM support Stefano Radaelli
@ 2026-09-17 15:41 ` Stefano Radaelli
  2026-09-17 15:41 ` [PATCH v2 2/3] arm64: dts: imx8mm-var-dart: add TPM support Stefano Radaelli
  2026-09-17 15:41 ` [PATCH v2 3/3] arm64: dts: imx8mm-var-dart: increase PHY reset deassert delay Stefano Radaelli
  2 siblings, 0 replies; 8+ messages in thread
From: Stefano Radaelli @ 2026-09-17 15:41 UTC (permalink / raw)
  To: Frank Li, linux-kernel, devicetree, imx, linux-arm-kernel
  Cc: pierluigi.p, Stefano Radaelli, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Sascha Hauer, Pengutronix Kernel Team,
	Fabio Estevam, Francesco Ferraro

From: Stefano Radaelli <stefano.r@variscite.com>

Configure SAI3 to operate in synchronous RX mode, so that the trasmit
path uses the receive bit clock and frame sync signals.

Remove the TX_SYNC and TX_BCLK pinmux entries, as these signals are not
used in this configuration.

Co-developed-by: Francesco Ferraro <francesco.f@variscite.com>
Signed-off-by: Francesco Ferraro <francesco.f@variscite.com>
Signed-off-by: Stefano Radaelli <stefano.r@variscite.com>
---
v1->v2:
 - 

 arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi
index 2324063f8fd9..c7a9eb23e5e8 100644
--- a/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi
+++ b/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi
@@ -305,6 +305,7 @@ &sai3 {
 	assigned-clock-parents = <&clk IMX8MM_AUDIO_PLL1_OUT>;
 	assigned-clock-rates = <1536000>;
 	fsl,sai-mclk-direction-output;
+	fsl,sai-synchronous-rx;
 	status = "okay";
 };
 
@@ -446,8 +447,6 @@ pinctrl_sai3: sai3grp {
 			MX8MM_IOMUXC_SAI3_RXFS_SAI3_RX_SYNC		0xd6
 			MX8MM_IOMUXC_SAI3_RXC_SAI3_RX_BCLK		0xd6
 			MX8MM_IOMUXC_SAI3_RXD_SAI3_RX_DATA0		0xd6
-			MX8MM_IOMUXC_SAI3_TXFS_SAI3_TX_SYNC		0xd6
-			MX8MM_IOMUXC_SAI3_TXC_SAI3_TX_BCLK		0xd6
 			MX8MM_IOMUXC_SAI3_TXD_SAI3_TX_DATA0		0xd6
 			MX8MM_IOMUXC_SAI3_MCLK_SAI3_MCLK		0xd6
 		>;
-- 
2.47.3


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH v2 2/3] arm64: dts: imx8mm-var-dart: add TPM support
  2026-09-17 15:41 [PATCH v2 0/3] arm64: dts: imx8mm-var-dart: update SoM support Stefano Radaelli
  2026-09-17 15:41 ` [PATCH v2 1/3] arm64: dts: imx8mm-var-dart: configure SAI3 synchronous RX mode Stefano Radaelli
@ 2026-09-17 15:41 ` Stefano Radaelli
  2026-09-17 15:50   ` sashiko-bot
  2026-09-17 15:41 ` [PATCH v2 3/3] arm64: dts: imx8mm-var-dart: increase PHY reset deassert delay Stefano Radaelli
  2 siblings, 1 reply; 8+ messages in thread
From: Stefano Radaelli @ 2026-09-17 15:41 UTC (permalink / raw)
  To: Frank Li, linux-kernel, devicetree, imx, linux-arm-kernel
  Cc: pierluigi.p, Stefano Radaelli, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Sascha Hauer, Pengutronix Kernel Team,
	Fabio Estevam, Nate Drude

From: Stefano Radaelli <stefano.r@variscite.com>

Add support for the TPM available on the Variscite DART-MX8M-MINI SOM.

Co-developed-by: Nate Drude <nate.d@variscite.com>
Signed-off-by: Nate Drude <nate.d@variscite.com>
Signed-off-by: Stefano Radaelli <stefano.r@variscite.com>
---
v1->v2:
 - Add tpm pinctrl
 - Add comment on tpm reset line

 .../boot/dts/freescale/imx8mm-var-dart.dtsi      | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi
index c7a9eb23e5e8..953950e55bf9 100644
--- a/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi
+++ b/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi
@@ -138,6 +138,16 @@ &i2c1 {
 	sda-gpios = <&gpio5 15 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
 	status = "okay";
 
+	st33ktpm2xi2c_som: tpm@2e {
+		compatible = "st,st33ktpm2xi2c", "tcg,tpm-tis-i2c";
+		reg = <0x2e>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&pinctrl_tpm_reset>;
+		label = "tpm";
+		/* active-low TPM reset line. */
+		reset-gpios = <&gpio4 31 GPIO_ACTIVE_HIGH>;
+	};
+
 	pmic@4b {
 		compatible = "rohm,bd71847";
 		reg = <0x4b>;
@@ -452,6 +462,12 @@ MX8MM_IOMUXC_SAI3_MCLK_SAI3_MCLK		0xd6
 		>;
 	};
 
+	pinctrl_tpm_reset: tpm-resetgrp {
+		fsl,pins = <
+			MX8MM_IOMUXC_SAI3_TXFS_GPIO4_IO31		0x19
+		>;
+	};
+
 	pinctrl_uart4: uart4grp {
 		fsl,pins = <
 			MX8MM_IOMUXC_ECSPI2_SCLK_UART4_DCE_RX		0x140
-- 
2.47.3


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH v2 3/3] arm64: dts: imx8mm-var-dart: increase PHY reset deassert delay
  2026-09-17 15:41 [PATCH v2 0/3] arm64: dts: imx8mm-var-dart: update SoM support Stefano Radaelli
  2026-09-17 15:41 ` [PATCH v2 1/3] arm64: dts: imx8mm-var-dart: configure SAI3 synchronous RX mode Stefano Radaelli
  2026-09-17 15:41 ` [PATCH v2 2/3] arm64: dts: imx8mm-var-dart: add TPM support Stefano Radaelli
@ 2026-09-17 15:41 ` Stefano Radaelli
  2 siblings, 0 replies; 8+ messages in thread
From: Stefano Radaelli @ 2026-09-17 15:41 UTC (permalink / raw)
  To: Frank Li, linux-kernel, devicetree, imx, linux-arm-kernel
  Cc: pierluigi.p, Stefano Radaelli, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Sascha Hauer, Pengutronix Kernel Team,
	Fabio Estevam, Nate Drude

From: Stefano Radaelli <stefano.r@variscite.com>

The Ethernet PHY reset signal also controls the regulators supplying
VDDA2P5 and VDD1P0, so releasing reset restores the PHY's 2.5 V and
1.0 V analog supplies.

The existing 100 ms reset deassertion delay is not sufficient for
reliable PHY detection. The TI DP83867 requires 200 ms of stabilization
after power-up before MDIO register access.

Increase the reset deassertion delay to 200 ms to ensure reliable PHY
detection across repeated boots.

Co-developed-by: Nate Drude <nate.d@variscite.com>
Signed-off-by: Nate Drude <nate.d@variscite.com>
Signed-off-by: Stefano Radaelli <stefano.r@variscite.com>
---
v1->v2:
 - 

 arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi
index 953950e55bf9..4d6a79bbb132 100644
--- a/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi
+++ b/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi
@@ -123,7 +123,7 @@ ethphy0: ethernet-phy@0 {
 			reg = <0>;
 			reset-gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
 			reset-assert-us = <10000>;
-			reset-deassert-us = <100000>;
+			reset-deassert-us = <200000>;
 			vddio-supply = <&reg_phy_vddio>;
 		};
 	};
-- 
2.47.3


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* Re: [PATCH v2 2/3] arm64: dts: imx8mm-var-dart: add TPM support
  2026-09-17 15:41 ` [PATCH v2 2/3] arm64: dts: imx8mm-var-dart: add TPM support Stefano Radaelli
@ 2026-09-17 15:50   ` sashiko-bot
  2026-09-17 18:51     ` Frank Li
  0 siblings, 1 reply; 8+ messages in thread
From: sashiko-bot @ 2026-09-17 15:50 UTC (permalink / raw)
  To: Stefano Radaelli; +Cc: conor+dt, robh, Frank.Li, imx, devicetree

Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] dts: incorrect reset-gpios polarity contradicts hardware description
--

commit 3fe00f46f78811d6ed3d86dcccba4b6f6cd29139
Author: Stefano Radaelli <stefano.r@variscite.com>

arm64: dts: imx8mm-var-dart: add TPM support

This commit adds device tree support for the TPM module available on the 
Variscite DART-MX8M-MINI SOM.

> diff --git a/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi
> index c7a9eb23e5e88..953950e55bf99 100644
> --- a/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi
> +++ b/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi
> @@ -138,6 +138,16 @@ &i2c1 {
>  	sda-gpios = <&gpio5 15 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
>  	status = "okay";
>  
> +	st33ktpm2xi2c_som: tpm@2e {
> +		compatible = "st,st33ktpm2xi2c", "tcg,tpm-tis-i2c";
> +		reg = <0x2e>;
> +		pinctrl-names = "default";
> +		pinctrl-0 = <&pinctrl_tpm_reset>;
> +		label = "tpm";
> +		/* active-low TPM reset line. */
> +		reset-gpios = <&gpio4 31 GPIO_ACTIVE_HIGH>;

[Severity: Low]
Does the device tree polarity match the actual hardware description here? The
GPIO_ACTIVE_HIGH flag directly contradicts the inline comment that the
physical line is active-low. Standard device tree practice requires the
logical flag to match the physical active state (GPIO_ACTIVE_LOW).

If this property is parsed by a bootloader (like U-Boot) or a future Linux 
driver update, wouldn't the reset line be driven to the wrong polarity (high 
for reset, low for de-assert), potentially holding the TPM in reset and 
breaking device initialization?

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/cover.1789659585.git.stefano.r@variscite.com?part=2

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH v2 2/3] arm64: dts: imx8mm-var-dart: add TPM support
  2026-09-17 15:50   ` sashiko-bot
@ 2026-09-17 18:51     ` Frank Li
  2026-09-17 19:14       ` Stefano Radaelli
  0 siblings, 1 reply; 8+ messages in thread
From: Frank Li @ 2026-09-17 18:51 UTC (permalink / raw)
  To: sashiko-reviews
  Cc: Stefano Radaelli, conor+dt, robh, Frank.Li, imx, devicetree

On Thu, Sep 17, 2026 at 03:50:33PM +0000, sashiko-bot@kernel.org wrote:
> Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
> - [Low] dts: incorrect reset-gpios polarity contradicts hardware description
> --
>
> commit 3fe00f46f78811d6ed3d86dcccba4b6f6cd29139
> Author: Stefano Radaelli <stefano.r@variscite.com>
>
> arm64: dts: imx8mm-var-dart: add TPM support
>
> This commit adds device tree support for the TPM module available on the
> Variscite DART-MX8M-MINI SOM.
>
> > diff --git a/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi
> > index c7a9eb23e5e88..953950e55bf99 100644
> > --- a/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi
> > +++ b/arch/arm64/boot/dts/freescale/imx8mm-var-dart.dtsi
> > @@ -138,6 +138,16 @@ &i2c1 {
> >  	sda-gpios = <&gpio5 15 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
> >  	status = "okay";
> >
> > +	st33ktpm2xi2c_som: tpm@2e {
> > +		compatible = "st,st33ktpm2xi2c", "tcg,tpm-tis-i2c";
> > +		reg = <0x2e>;
> > +		pinctrl-names = "default";
> > +		pinctrl-0 = <&pinctrl_tpm_reset>;
> > +		label = "tpm";
> > +		/* active-low TPM reset line. */
> > +		reset-gpios = <&gpio4 31 GPIO_ACTIVE_HIGH>;
>
> [Severity: Low]
> Does the device tree polarity match the actual hardware description here? The
> GPIO_ACTIVE_HIGH flag directly contradicts the inline comment that the
> physical line is active-low. Standard device tree practice requires the
> logical flag to match the physical active state (GPIO_ACTIVE_LOW).
>
> If this property is parsed by a bootloader (like U-Boot) or a future Linux
> driver update, wouldn't the reset line be driven to the wrong polarity (high
> for reset, low for de-assert), potentially holding the TPM in reset and
> breaking device initialization?

tpm_tis_core.c have not parser reset-gpios. ref

static int reset_gpio_assert(struct reset_controller_dev *rc, unsigned long id)
{
        struct reset_gpio_priv *priv = rc_to_reset_gpio(rc);

        return gpiod_set_value_cansleep(priv->reset, 1);
}

suppose it should be GPIO_ACTIVE_LOW to assert reset line

Frank

>
> --
> Sashiko AI review · https://sashiko.dev/#/patchset/cover.1789659585.git.stefano.r@variscite.com?part=2

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH v2 2/3] arm64: dts: imx8mm-var-dart: add TPM support
  2026-09-17 18:51     ` Frank Li
@ 2026-09-17 19:14       ` Stefano Radaelli
  2026-09-17 19:52         ` Frank Li
  0 siblings, 1 reply; 8+ messages in thread
From: Stefano Radaelli @ 2026-09-17 19:14 UTC (permalink / raw)
  To: Frank Li; +Cc: sashiko-reviews, conor+dt, robh, Frank.Li, imx, devicetree

On Thu, Sep 17, 2026 at 01:51:57PM -0500, Frank Li wrote:
> 
> tpm_tis_core.c have not parser reset-gpios. ref
> 
> static int reset_gpio_assert(struct reset_controller_dev *rc, unsigned long id)
> {
>         struct reset_gpio_priv *priv = rc_to_reset_gpio(rc);
> 
>         return gpiod_set_value_cansleep(priv->reset, 1);
> }
> 
> suppose it should be GPIO_ACTIVE_LOW to assert reset line
> 
> Frank

Thanks Frank.

You're right, tpm_tis_i2c currently does not parse a reset control.
I have proposed a separate patch to add optional reset support using
the reset framework:

https://patchwork.kernel.org/project/linux-integrity/patch/20260917124211.136221-1-stefano.r@variscite.com/

Also, the reset line is active-low, so you are right, GPIO_ACTIVE_LOW
is the correct polarity here.

Would you prefer me to send v3 without the TPM DTS patch for now,
and add it back once the reset support patch has been accepted?

Best Regards,
Stefano

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH v2 2/3] arm64: dts: imx8mm-var-dart: add TPM support
  2026-09-17 19:14       ` Stefano Radaelli
@ 2026-09-17 19:52         ` Frank Li
  0 siblings, 0 replies; 8+ messages in thread
From: Frank Li @ 2026-09-17 19:52 UTC (permalink / raw)
  To: Stefano Radaelli
  Cc: sashiko-reviews, conor+dt, robh, Frank.Li, imx, devicetree

On Thu, Sep 17, 2026 at 09:14:19PM +0200, Stefano Radaelli wrote:
> On Thu, Sep 17, 2026 at 01:51:57PM -0500, Frank Li wrote:
> >
> > tpm_tis_core.c have not parser reset-gpios. ref
> >
> > static int reset_gpio_assert(struct reset_controller_dev *rc, unsigned long id)
> > {
> >         struct reset_gpio_priv *priv = rc_to_reset_gpio(rc);
> >
> >         return gpiod_set_value_cansleep(priv->reset, 1);
> > }
> >
> > suppose it should be GPIO_ACTIVE_LOW to assert reset line
> >
> > Frank
>
> Thanks Frank.
>
> You're right, tpm_tis_i2c currently does not parse a reset control.
> I have proposed a separate patch to add optional reset support using
> the reset framework:
>
> https://patchwork.kernel.org/project/linux-integrity/patch/20260917124211.136221-1-stefano.r@variscite.com/
>
> Also, the reset line is active-low, so you are right, GPIO_ACTIVE_LOW
> is the correct polarity here.
>
> Would you prefer me to send v3 without the TPM DTS patch for now,
> and add it back once the reset support patch has been accepted?

You leave reset-gpios if binding already here. Just need fix GPIO_ACTIVE_LOW

Frank

>
> Best Regards,
> Stefano

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2026-09-17 19:53 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-17 15:41 [PATCH v2 0/3] arm64: dts: imx8mm-var-dart: update SoM support Stefano Radaelli
2026-09-17 15:41 ` [PATCH v2 1/3] arm64: dts: imx8mm-var-dart: configure SAI3 synchronous RX mode Stefano Radaelli
2026-09-17 15:41 ` [PATCH v2 2/3] arm64: dts: imx8mm-var-dart: add TPM support Stefano Radaelli
2026-09-17 15:50   ` sashiko-bot
2026-09-17 18:51     ` Frank Li
2026-09-17 19:14       ` Stefano Radaelli
2026-09-17 19:52         ` Frank Li
2026-09-17 15:41 ` [PATCH v2 3/3] arm64: dts: imx8mm-var-dart: increase PHY reset deassert delay Stefano Radaelli

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox