[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <d40e69bc-d020-4aa0-be1a-b78bb11fe68c@lunn.ch>
Date: Thu, 13 Apr 2023 00:10:55 +0200
From: Andrew Lunn <andrew@...n.ch>
To: Ron Eggler <ron.eggler@...tywest.com>
Cc: netdev@...r.kernel.org
Subject: Re: issues to bring up two VSC8531 PHYs
On Wed, Apr 12, 2023 at 01:11:45PM -0700, Ron Eggler wrote:
> Hi,
> I am trying to bring up a pair of VSC9531 PHYs on an embedded system. I'm using a Yocto build and have altered the device tree with the following patch:
> https://github.com/MistySOM/meta-mistysom/blob/phy-enable/recipes-kernel/linux/smarc-rzg2l/0001-add-vsc8531-userspace-dts.patch
+ phy0: ethernet-phy@7 {
+ compatible = "ethernet-phy-ieee802.3-c45";
+ reg = <0>;
There is a minor DT issue here. I assume the PHY is on address 0 of
the bus? Then ethernet-phy@7 should be ethernet-phy@0. This is pretty
much cosmetic, but when you come to submit the board for inclusion in
mainline, you need to have this correct.
> I installed mdio-tools and can see the interfaces like:
> # mdio
> 11c20000.ethernet-ffffffff
> 11c30000.ethernet-ffffffff
>
> Also, I hooked up a logic analyzer to the mdio lines and can see communications happening at boot time. Also, it appears that it's able to read the link status correctly (when a cable is plugged):
> # mdio 11c20000.ethernet-ffffffff
> DEV PHY-ID LINK
> 0x00 0x00070572 up
So that matches with:
/linux/drivers/net/phy$ grep -r 000705 *
mscc/mscc.h:#define PHY_ID_VSC8531 0x00070570
Take a look in sys/bus/mdio_bus/devices/ Any sign of the two PHYs?
> Yet, ifconfig doesn't show the interfaces and I get:
> # ifconfig eth0 up
> [ 140.542939] ravb 11c20000.ethernet eth0: failed to connect PHY
So this is where you need to start debugging. Why cannot it find the
PHY?
Your DT patch does not show a phy-handle. Is there one inherited from
a .dtsi files? Is phy-mode also set?
Andrew
Powered by blists - more mailing lists