This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/AM3352: AM335x: cannot find ethernet PHY in using CPSW

Part Number: AM3352

Tool/software: Linux

Hello.

- Board : custum board like AM335x EVM.

- Linux : Arago base(Linux am335x-evm 4.9.65-rt23-g7069a470d5 #20 PREEMPT RT Tue Nov 6 16:06:32 JST 2018 armv7l GNU/Linux)

  - TI PROCESSOR SDK 04.03.00.05(RT)

I have a 2 ethernet PHYs and 1 USB-Ethernet bridge in my board. The ethernet PHYs have MII connection.

But I can find only eth0 in using CPSW as dual emac. And each one is not linking-up.

Kernel found 2 PHYs in mdio-bus in following log:

[    1.109668] davinci_mdio 4a101000.mdio: phy[1]: device 4a101000.mdio:01, driver TI DP83822 10/100 Mbps PHY
[    1.119369] davinci_mdio 4a101000.mdio: phy[2]: device 4a101000.mdio:02, driver TI DP83822 10/100 Mbps PHY

I think 2 ethernet PHYs are detected as eth0 and eth1, but USB-ethernet bridge as eth1.

What should I do to detect 2nd ethernet PHY as eth1?

Then, I share my device tree and dmesg log.

 

Best regards.

Nish

 

share-log.zip

  • Hi,
    My suggestion is to concentrate on one interface at a time. So lets look at eth0 based on the ethtool output. The dmesg log shows that phy for eth0 answering on the mdio bus at the correct address. The ethtool output at the end of the dmesg file is indicating that a link is not detected. Why the link is not happening needs to be determined first, until a link is detected and the port an ip address no data will pass.

    root@am335x-evm:~# ethtool eth0
    Settings for eth0:
    Speed: 10Mb/s
    Duplex: Half
    Port: MII
    PHYAD: 1
    ......
    Link detected: no

    The DTS entries look OK for eth0 but there is no link detected. This typically is a PHY issue as the link detection happens independent of any software bring up.

    Best Regards,
    Schuyler
  • Hishare-log2.zip.

    OK. First, I concentrate on one interface.

    So, I delete dual emac entry from my DTS. Then, I found new message:

    [    1.129731] cpsw 4a100000.ethernet: No slave[1] phy_id, phy-handle, or fixed-link property

    What does this message mean?

    Best regards.

    Nish

  • Hi.

    The situation is improved.
    My custom board has a mistake in power supply layout.
    (When the system power switch is turned off, 3.3V power supply remains...)
    -> 3.3V power supply is shutdown, and then power is turned on, I got a one PHY Link-up!!
    I resolved the problem on one interface.

    So next problem, 2nd PHY is not detect as eth1.
    What should I observe?

    Best Regards.
    Nishihashi
  • Hello.

    Schuyler says:
    This typically is a PHY issue as the link detection happens independent of any software bring up.

    This is correct.
    I got 2nd PHY Link-up.

    Any other modification I have done (excluding previous reply):
    *DTS entry has modified like am335x-evmsk.dts.

    Thanks for your advice.
    It's resolved.

    Best regards.
    Nishihashi