devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] arm64: dts: imx8mm-evk: add phy-reset-gpios for fec1
@ 2020-02-14 19:27 Alifer Moraes
  2020-02-14 19:27 ` [PATCH 2/2] arm64: dts: imx8mq-evk: " Alifer Moraes
                   ` (3 more replies)
  0 siblings, 4 replies; 12+ messages in thread
From: Alifer Moraes @ 2020-02-14 19:27 UTC (permalink / raw)
  To: robh+dt
  Cc: mark.rutland, shawnguo, s.hauer, kernel, festevam, linux-imx,
	peng.fan, leonard.crestez, devicetree, linux-kernel,
	Alifer Moraes

imx8mm-evk has a GPIO connected to AR8031 Ethernet PHY's reset pin.

Describe it in the device tree, following phy's datasheet reset duration of 10ms.

Tested booting via NFS.

Signed-off-by: Alifer Moraes <alifer.wsdm@gmail.com>
---

Originally sent by Peng Fan <peng.fan@nxp.com>

Back then CONFIG_AT803X_PHY was set as "m" in defconfig so the boot process hung
at nfs boot, now that CONFIG_AT803X_PHY is set as "y" by default, the patch works
correctly.

Peng's original patch missed to pass the phy-reset-duration, according to the AR8031
datasheet the reset GPIO needs to stay low for 10ms.

Original thread: https://lkml.org/lkml/2019/10/21/347

 arch/arm64/boot/dts/freescale/imx8mm-evk.dts | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/arm64/boot/dts/freescale/imx8mm-evk.dts b/arch/arm64/boot/dts/freescale/imx8mm-evk.dts
index 28ab17a277bb..11903ca86f0e 100644
--- a/arch/arm64/boot/dts/freescale/imx8mm-evk.dts
+++ b/arch/arm64/boot/dts/freescale/imx8mm-evk.dts
@@ -82,6 +82,8 @@
 	pinctrl-0 = <&pinctrl_fec1>;
 	phy-mode = "rgmii-id";
 	phy-handle = <&ethphy0>;
+	phy-reset-gpios = <&gpio4 22 GPIO_ACTIVE_LOW>;
+	phy-reset-duration = <10>;
 	fsl,magic-packet;
 	status = "okay";
 
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 12+ messages in thread
* [PATCH 1/2] arm64: dts: imx8mm-evk: add phy-reset-gpios for fec1
@ 2019-10-21  9:21 Peng Fan
  2019-10-21  9:44 ` Marco Felsch
  0 siblings, 1 reply; 12+ messages in thread
From: Peng Fan @ 2019-10-21  9:21 UTC (permalink / raw)
  To: robh+dt, mark.rutland, shawnguo, s.hauer, kernel, festevam
  Cc: dl-linux-imx, Anson Huang, Leonard Crestez, Daniel Baluta,
	Jacky Bai, Jun Li, devicetree, linux-arm-kernel, linux-kernel,
	Andy Duan, Peng Fan

From: Peng Fan <peng.fan@nxp.com>

We should not rely on U-Boot to configure the phy reset.
So introduce phy-reset-gpios property to let Linux handle phy reset
itself.

Signed-off-by: Peng Fan <peng.fan@nxp.com>
---
 arch/arm64/boot/dts/freescale/imx8mm-evk.dts | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm64/boot/dts/freescale/imx8mm-evk.dts b/arch/arm64/boot/dts/freescale/imx8mm-evk.dts
index faefb7182af1..e4d66f7db09d 100644
--- a/arch/arm64/boot/dts/freescale/imx8mm-evk.dts
+++ b/arch/arm64/boot/dts/freescale/imx8mm-evk.dts
@@ -80,6 +80,7 @@
 	pinctrl-0 = <&pinctrl_fec1>;
 	phy-mode = "rgmii-id";
 	phy-handle = <&ethphy0>;
+	phy-reset-gpios = <&gpio4 22 GPIO_ACTIVE_LOW>;
 	fsl,magic-packet;
 	status = "okay";
 
-- 
2.16.4


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

end of thread, other threads:[~2020-02-24  1:37 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-14 19:27 [PATCH 1/2] arm64: dts: imx8mm-evk: add phy-reset-gpios for fec1 Alifer Moraes
2020-02-14 19:27 ` [PATCH 2/2] arm64: dts: imx8mq-evk: " Alifer Moraes
2020-02-17  8:21   ` Marco Felsch
2020-02-19  1:16   ` Fabio Estevam
2020-02-17  8:20 ` [PATCH 1/2] arm64: dts: imx8mm-evk: " Marco Felsch
2020-02-18 13:02   ` Alifer Moraes
2020-02-19  1:15 ` Fabio Estevam
2020-02-24  1:37 ` Shawn Guo
  -- strict thread matches above, loose matches on Subject: below --
2019-10-21  9:21 Peng Fan
2019-10-21  9:44 ` Marco Felsch
2019-10-21  9:46   ` Peng Fan
2019-10-21  9:50     ` Marco Felsch

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).