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/AM5718: PHY not detected

Part Number: AM5718

Tool/software: Linux

Hi,

we have developed a custom board with AM5718 using ti-processor-sdk-linux-am57xx-evm-05.02.00.10. we have an issue with Ethernet, almost every thing is over in bringing up the som except this Ethernet issue, Please try to help us to resolve this issue.

In our board

1. One port realized with RMI and another port is relaized with PCIe using i210 and this is also RMI
2. ENET-REF-50MHz is connected between processor and PHY





3. We are using internal clock from the processor
4. The phy address is 9, which is depend on hardware.

Ethernet pin configurations and nodes in our dts file.

       davinci_mdio_pins: pinmux_davinci_mdio_pins {
            pinctrl-single,pins = <
                /* MDIO */
            DRA7XX_CORE_IOPAD(0x363c, PIN_OUTPUT_PULLUP | MUX_MODE1)                /* mdio_mclk */
            DRA7XX_CORE_IOPAD(0x3640, PIN_INPUT_PULLUP | MUX_MODE1)                  /* mdio_d */

        >;
        };

       davinci_mdio_pins_sleep: pinmux_davinci_mdio_pins_sleep {
        pinctrl-single,pins = <
                /* MDIO reset value */
            DRA7XX_CORE_IOPAD(0x363c, PIN_INPUT_PULLDOWN | MUX_MODE15)                /* mdio_mclk */
            DRA7XX_CORE_IOPAD(0x3640, PIN_INPUT_PULLDOWN | MUX_MODE15)                  /* mdio_d */

        >;
        };


    cpsw_pins_default: cpsw_pins_default {
         pinctrl-single,pins = <
             /* Slave 1 */
            DRA7XX_CORE_IOPAD(0x3650, PIN_OUTPUT | MUX_MODE1)    /* rgmii1_tclk */
            DRA7XX_CORE_IOPAD(0x3644, PIN_OUTPUT | MUX_MODE0)    /* rgmii1_tclk---RMII_MHZ_50_CLK */
            DRA7XX_CORE_IOPAD(0x3654, PIN_OUTPUT | MUX_MODE1)    /* rgmii1_tctl */
            DRA7XX_CORE_IOPAD(0x3658, PIN_OUTPUT | MUX_MODE1)    /* rgmii1_td3 */
            DRA7XX_CORE_IOPAD(0x365c, PIN_OUTPUT | MUX_MODE1)    /* rgmii1_td2 */
            DRA7XX_CORE_IOPAD(0x3660, PIN_OUTPUT | MUX_MODE1)    /* rgmii1_td1 */
            DRA7XX_CORE_IOPAD(0x3664, PIN_OUTPUT | MUX_MODE1)    /* rgmii1_td0 */
            DRA7XX_CORE_IOPAD(0x3668, PIN_INPUT | MUX_MODE1)    /* rgmii1_rclk */
            DRA7XX_CORE_IOPAD(0x366c, PIN_INPUT | MUX_MODE1)    /* rgmii1_rctl */
            DRA7XX_CORE_IOPAD(0x3670, PIN_INPUT | MUX_MODE1)    /* rgmii1_rd3 */
            DRA7XX_CORE_IOPAD(0x3674, PIN_INPUT | MUX_MODE1)    /* rgmii1_rd2 */
            DRA7XX_CORE_IOPAD(0x3678, PIN_INPUT | MUX_MODE1)    /* rgmii1_rd1 */
            DRA7XX_CORE_IOPAD(0x367c, PIN_INPUT | MUX_MODE1)    /* rgmii1_rd0 */

>;

};

&mac {
    status = "okay";
    pinctrl-names = "default";
    pinctrl-0 = <&cpsw_pins_default>;
    pinctrl-1 = <&cpsw_pins_sleep>;
    //dual_emac;
    slaves = <1>;
};

&cpsw_emac0 {

                phy_id = <&davinci_mdio>,<9>;
                phy-mode = "rmii";
   
        
};

&davinci_mdio {
       status = "okay";
       pinctrl-names = "default", "sleep";
       pinctrl-0 = <&davinci_mdio_pins>;
       pinctrl-1 = <&davinci_mdio_pins_sleep>;

};

In the boot log

[    1.727440] libphy: Fixed MDIO Bus: probed
[    1.790842] davinci_mdio 48485000.mdio: davinci mdio revision 1.6, bus freq 1000000
[    1.798535] davinci_mdio 48485000.mdio: no live phy, scanning all
[    1.900955] davinci_mdio 48485000.mdio: timed out waiting for user access
[    2.007850] davinci_mdio 48485000.mdio: timed out waiting for idle
[    2.014106] davinci_mdio: probe of 48485000.mdio failed with error -5
[    2.021186] CTRL_CORE_MAC_ID_SW_1  985dad
[    2.025213] CTRL_CORE_MAC_ID_SW_0  9a2e1a
[    2.029236] mac addr[i] 98
[    2.031970] mac addr[i] 5d
[    2.034687] mac addr[i] ad
[    2.037401] mac addr[i] 9a
[    2.040115] mac addr[i] 2e
[    2.042844] mac addr[i] 1a
[    2.045563] cpsw 48484000.ethernet: Detected MACID = 98:5d:ad:9a:2e:1a
[    2.052187] cpsw 48484000.ethernet: initialized cpsw ale version 1.4
[    2.058568] cpsw 48484000.ethernet: ALE Table size 1024
[    2.063841] cpsw 48484000.ethernet: device node lookup for pps timer failed
[    2.070881] cpsw 48484000.ethernet: cpts: overflow check period 500 (jiffies)

root@am57xx-evm:~# dmesg | grep phy
[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] arch_timer: cp15 timer(s) running at 6.14MHz (phys).
[    1.727440] libphy: Fixed MDIO Bus: probed
[    1.798535] davinci_mdio 48485000.mdio: no live phy, scanning all
[    9.546973] libphy: PHY 48485000.mdio:09 not found
[    9.546979] net eth0: phy "48485000.mdio:09" not found on slave 0, err -19
root@am57xx-evm:~# dmesg | grep eth
[    2.045563] cpsw 48484000.ethernet: Detected MACID = 98:5d:ad:9a:2e:1a
[    2.052187] cpsw 48484000.ethernet: initialized cpsw ale version 1.4
[    2.058568] cpsw 48484000.ethernet: ALE Table size 1024
[    2.063841] cpsw 48484000.ethernet: device node lookup for pps timer failed
[    2.070881] cpsw 48484000.ethernet: cpts: overflow check period 500 (jiffies)
[    9.544979] net eth0: initializing cpsw version 1.15 (0)
[    9.546979] net eth0: phy "48485000.mdio:09" not found on slave 0, err -19
[    9.577599] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
root@am57xx-evm:~#