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.

AM3356: Adding compatible = "ethernet-phy-ieee802.3-c45" or compatible = "ethernet-phy-ieee802.3-c22" property to the PHY

Part Number: AM3356

I am using the latest TI release  with Linux version 5.10.100  on AM3356 CPU.

I have configured the CPSW in the  device tree to operate in dual_emac mode as described in software-dl.ti.com/.../CPSW.html

&mac {
     pinctrl-names = "default", "sleep";  
     pinctrl-0 = <&cpsw_default>;
     pinctrl-1 = <&cpsw_sleep>;
    dual_emac = <1>;
    status = "okay";
};

&davinci_mdio {
   pinctrl-names = "default", "sleep";
   pinctrl-0 = <&davinci_mdio_default>;     
   pinctrl-1 = <&davinci_mdio_sleep>;
   bus_freq = <2500000>;
   status = "okay";

   ethphy0: ethernet-phy@0 {
      reg = <0>;                           /* First PHY address is 0 */
   };
   ethphy1: ethernet-phy@1 {
      reg = <1>;                           /* Second PHY address is 1 */
   };
};

&cpsw_emac0 {
   phy-handle = <&ethphy0>;
   phy-mode = "rmii";
   dual_emac_res_vlan = <1>;
};

&cpsw_emac1 {
   phy-handle = <&ethphy1>;
   phy-mode = "rmii";
   dual_emac_res_vlan = <2>;
};

The first eth0 port is working fine. I still have some problems with the second one and I assume that is a hardware related problem.

Now I want to add the compatible = "ethernet-phy-ieee802.3-c45"  or compatible = "ethernet-phy-ieee802.3-c22"  property to any PHY. (One PHY supports C22 and the second supports both C22 & C45)

 ethphy1: ethernet-phy@1 {
      reg = <1>;

      compatible = "ethernet-phy-ieee802.3-c45";
   };

or 

ethphy1: ethernet-phy@1 {
      reg = <1>;

     compatible = "ethernet-phy-ieee802.3-c22";
   };

After doing so, the first slave eth0 port stops working.  This happens after adding any "compatability = " property to any of the 2 PHYs.

Is there  a problem to add  compatible = "ethernet-phy-ieee802.3-c45"  or  compatible = "ethernet-phy-ieee802.3-c45" property for davinci_mdio bus  in the device tree?

Thx

Martin Roth

Motorola Solutions