devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1] ARM: dts: protonic prti6q: fix PHY address
@ 2020-10-12  7:18 Oleksij Rempel
  2020-10-30  8:50 ` Shawn Guo
  0 siblings, 1 reply; 2+ messages in thread
From: Oleksij Rempel @ 2020-10-12  7:18 UTC (permalink / raw)
  To: Mark Rutland, Rob Herring, Sascha Hauer, Shawn Guo
  Cc: Oleksij Rempel, devicetree, Fabio Estevam, linux-arm-kernel,
	linux-kernel, NXP Linux Team, Pengutronix Kernel Team,
	David Jander

Due to bug in the bootloader, the PHY has floating address and may
randomly change on each PHY reset. To avoid it, the updated bootloader
with the following patch[0] should be used:

| ARM: protonic: disable on-die termination to fix PHY bootstrapping
|
| If on-die termination is enabled, the RXC pin of iMX6 will be pulled
| high. Since we already have an 10K pull-down on board, the RXC level on
| PHY reset will be ~800mV, which is mostly interpreted as 1. On some
| reboots we get 0 instead and kernel can't detect the PHY properly.
|
| Since the default 0x020e07ac value is 0, it is sufficient to remove this
| entry from the affected imxcfg files.
|
| Since we get stable 0 on pin PHYADDR[2], the PHY address is changed from
| 4 to 0.

With latest bootloader update, the PHY address will be fixed to "0".

[0] https://git.pengutronix.de/cgit/barebox/commit/?id=93f7dcf631edfcda19e7757b28d66017ea274b81

Fixes: 0d446a50559 ("ARM: dts: add Protonic PRTI6Q board")
Signed-off-by: Oleksij Rempel <o.rempel@pengutronix.de>
---
 arch/arm/boot/dts/imx6q-prti6q.dts | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/boot/dts/imx6q-prti6q.dts b/arch/arm/boot/dts/imx6q-prti6q.dts
index de6cbaab8b49..671bb3a6665d 100644
--- a/arch/arm/boot/dts/imx6q-prti6q.dts
+++ b/arch/arm/boot/dts/imx6q-prti6q.dts
@@ -213,8 +213,8 @@ mdio {
 		#size-cells = <0>;
 
 		/* Microchip KSZ9031RNX PHY */
-		rgmii_phy: ethernet-phy@4 {
-			reg = <4>;
+		rgmii_phy: ethernet-phy@0 {
+			reg = <0>;
 			interrupts-extended = <&gpio1 28 IRQ_TYPE_LEVEL_LOW>;
 			reset-gpios = <&gpio1 25 GPIO_ACTIVE_LOW>;
 			reset-assert-us = <10000>;
-- 
2.28.0


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

* Re: [PATCH v1] ARM: dts: protonic prti6q: fix PHY address
  2020-10-12  7:18 [PATCH v1] ARM: dts: protonic prti6q: fix PHY address Oleksij Rempel
@ 2020-10-30  8:50 ` Shawn Guo
  0 siblings, 0 replies; 2+ messages in thread
From: Shawn Guo @ 2020-10-30  8:50 UTC (permalink / raw)
  To: Oleksij Rempel
  Cc: Mark Rutland, Rob Herring, Sascha Hauer, devicetree,
	Fabio Estevam, linux-arm-kernel, linux-kernel, NXP Linux Team,
	Pengutronix Kernel Team, David Jander

On Mon, Oct 12, 2020 at 09:18:16AM +0200, Oleksij Rempel wrote:
> Due to bug in the bootloader, the PHY has floating address and may
> randomly change on each PHY reset. To avoid it, the updated bootloader
> with the following patch[0] should be used:
> 
> | ARM: protonic: disable on-die termination to fix PHY bootstrapping
> |
> | If on-die termination is enabled, the RXC pin of iMX6 will be pulled
> | high. Since we already have an 10K pull-down on board, the RXC level on
> | PHY reset will be ~800mV, which is mostly interpreted as 1. On some
> | reboots we get 0 instead and kernel can't detect the PHY properly.
> |
> | Since the default 0x020e07ac value is 0, it is sufficient to remove this
> | entry from the affected imxcfg files.
> |
> | Since we get stable 0 on pin PHYADDR[2], the PHY address is changed from
> | 4 to 0.
> 
> With latest bootloader update, the PHY address will be fixed to "0".
> 
> [0] https://git.pengutronix.de/cgit/barebox/commit/?id=93f7dcf631edfcda19e7757b28d66017ea274b81
> 
> Fixes: 0d446a50559 ("ARM: dts: add Protonic PRTI6Q board")
> Signed-off-by: Oleksij Rempel <o.rempel@pengutronix.de>

Changed subject prefix to 'ARM: dts: imx6q-prti6q: ' and applied the
patch.

Shawn

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

end of thread, other threads:[~2020-10-30  8:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-12  7:18 [PATCH v1] ARM: dts: protonic prti6q: fix PHY address Oleksij Rempel
2020-10-30  8:50 ` Shawn Guo

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