AnsweredAssumed Answered

MAC(sg.m2) configuration with SERDES 0x40 in T1022

Question asked by Hemwant Rawat on Jun 20, 2019
Latest reply on Sep 12, 2019 by Hemwant Rawat

I am having a customised board with T1022 processor, the SERDES configuration as used through RCW in the board is 0x40. I am trying to establish connection between MAC (sg.m2) of processor with 1G/2.5G Ethernet PCS/PMA IP core of Xilinx within Artix/FPGA device(XC7A200T-2FFG1156C) . 

I have configured Fixed link with 1000Mbps speed and full duplex mode in device tree of the board. After making the changes, the processor side connection is displayed with 1000Mbps and full duplex mode when checked through ethtool command in processor. 1G/2.5G Ethernet PCS

But on FPGA side when the auto negotiation of IP is enabled, IP  status vector indicates the link is established on 10Mbps and half-duplex mode. When auto negotiation is disabled then IP  status vector indicates that IP is getting auto negotiation  sequences from the processor.

Is there any registers to check the link status of the processor MAC(sg.m2) and control the speed and auto negotiation so that it can be correctly configured with FPGA/Artix device.

 

//Entry in device tree of T1022 board

aliases {
        rgmii_phy1 = &rgmii_phy1;
        rgmii_phy2 = &rgmii_phy2;
        phy_sgmii_2 = &phy_sgmii_2;
        phy_sgmii_1 = &phy_sgmii_1;
        phy_sgmii_0 = &phy_sgmii_0;
    };

 


    soc: soc@ffe000000 {
        fman0: fman@400000 {
            rcpm-wakeup = <&rcpm 0x00000008>;

 

            
            enet0: ethernet@e0000 {
                               /* fixed-link = <0 1 1000 0 0>;
                                phy-connection-type = "sgmii";

 

                rcpm-wakeup = <&rcpm 0x80000000>;*/
            };

 


            enet1: ethernet@e2000 {
                tbi-handle = <&tbi1>;
                                fixed-link = <1 1 1000 0 0>;
                                phy-connection-type = "sgmii";
                        rcpm-wakeup = <&rcpm 0x40000000>;
                         status = "okay";
            };

 

            enet2: ethernet@e4000 {
                tbi-handle = <&tbi0>;
                phy-handle = <&phy_sgmii_2>;
                phy-connection-type = "sgmii";
                rcpm-wakeup = <&rcpm 0x20000000>;
            };

 

            /* TI phy*/
            enet3: ethernet@e6000 {
                phy-handle = <&rgmii_phy1>;
                phy-connection-type = "rgmii-id";
                rcpm-wakeup = <&rcpm 0x10000000>;
            };
            
            /* Ti phy */
            enet4: ethernet@e8000 {
                phy-handle = <&rgmii_phy2>;
                phy-connection-type = "rgmii-id";
                rcpm-wakeup = <&rcpm 0x08000000>;
            };

 

            mdio0: mdio@fc000{

 

            tbi0: tbi-phy@5 {
                                        reg = <0x5>;
                                        device_type = "tbi-phy";
                             };
                        tbi1: tbi-phy@1f {
                        device_type = "tbi-phy";
                        reg = <0x1F>;
                         };
                rgmii_phy1: ethernet-phy@1 { /* MAC3 */
                        reg = <0x1>;
                    };
                rgmii_phy2: ethernet-phy@4 { /* MAC3 */
                        reg = <0x4>;
                    };

 

                phy_sgmii_2: ethernet-phy@14 {
                                        reg = <0x14>;
                                };

 

                phy_sgmii_1: ethernet-phy@17 {
                                        reg = <0x17>;
                                };
                phy_sgmii_0: ethernet-phy@16 {
                                        reg = <0x16>;
                                };
            };        
        };
    };

 

    fsl,dpaa {
        compatible = "fsl,t1040-dpaa", "fsl,dpaa";
        ethernet@0 {
            compatible = "fsl,t1040-dpa-ethernet",
                    "fsl,dpa-ethernet";
            fsl,fman-mac = <&enet0>;
        };
        ethernet@1 {
            compatible = "fsl,t1040-dpa-ethernet",
                    "fsl,dpa-ethernet";
            fsl,fman-mac = <&enet1>;
        };
        ethernet@2 {
            compatible = "fsl,t1040-dpa-ethernet",
                    "fsl,dpa-ethernet";
            fsl,fman-mac = <&enet2>;
        };
        ethernet@3 {
            compatible = "fsl,t1040-dpa-ethernet",
                    "fsl,dpa-ethernet";
            fsl,fman-mac = <&enet3>;
        };
        ethernet@4 {
            compatible = "fsl,t1040-dpa-ethernet",
                    "fsl,dpa-ethernet";
            fsl,fman-mac = <&enet4>;
        };
    };

Outcomes