2367273_en-US

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

2367273_en-US

2367273_en-US

SJA1110A DSA bring UP : 100BASE-TX TX failure and T1 link training issues

Hello,

I am bringing up an SJA1110AEL switch connected to a Microchip PolarFire SoC over SPI using the Linux DSA sja1105 driver from the Microchip Linux 6.12 FPGA tree:

https://github.com/linux4microchip/linux/tree/linux-6.12-mchp%2Bfpga/drivers/net/dsa/sja1105

The switch is configured in SPI boot mode (BOOT_OPTION=11), and the static configuration upload appears successful.

[    2.546758] sja1105 spi9.0: Probed switch chip: SJA1110A
[    2.546777] sja1105 spi9.0: max_xfer_len = 256 bytes
[    2.549576] sja1105 spi9.0: Config buffer length: 1776 bytes
[    2.549605] sja1105 spi9.0: Config buffer device_id at offset 0: 0x0f0300b7
[    2.742531] sja1105 status decoded: CONFIGS=1 CRCCHKL=0 IDS=0 CRCCHKG=0 NSLOT=9
[    2.742563] sja1105 spi9.0: sja1105_static_config_load done
[    2.742579] sja1105 spi9.0: sja1105_clocking done
[    2.742592] sja1105 spi9.0: sja1105_TAS and flower setup done
[    2.743823] sja1105 spi9.0: sja1105_ptp_clock_register done
[    2.888661] sja1105 spi9.0: sja1105_mdiobus_register done
[    2.888699] sja1105 spi9.0: sja1105_devlink_setup done
[    2.902778] sja1105 spi9.0: dsa_tag_8021q_register and rtnl_unlockdone
[    2.904141] sja1105 spi9.0: configuring for fixed/sgmii link mode
[    2.909745] sja1105 spi9.0: Link is Up - 1Gbps/Full - flow control off
[    2.964511] sja1105 spi9.0 rj45 (uninitialized): PHY [spi9.0-base-tx:01] driver [NXP CBTX (SJA1110)] (irq=POLL)
[    2.973125] sja1105 spi9.0 t1-1 (uninitialized): PHY [spi9.0-base-t1:01] driver [Generic Clause 45 PHY] (irq=POLL)
[    2.976322] sja1105 spi9.0 t1-2 (uninitialized): PHY [spi9.0-base-t1:02] driver [Generic Clause 45 PHY] (irq=POLL)
[    2.979382] sja1105 spi9.0 t1-3 (uninitialized): PHY [spi9.0-base-t1:03] driver [Generic Clause 45 PHY] (irq=POLL)
[    2.982622] sja1105 spi9.0 t1-4 (uninitialized): PHY [spi9.0-base-t1:04] driver [Generic Clause 45 PHY] (irq=POLL)
[    2.985855] sja1105 spi9.0 t1-5 (uninitialized): PHY [spi9.0-base-t1:05] driver [Generic Clause 45 PHY] (irq=POLL)
[    2.989002] sja1105 spi9.0 t1-6 (uninitialized): PHY [spi9.0-base-t1:06] driver [Generic Clause 45 PHY] (irq=POLL)
[    2.991420] macb 20110000.ethernet eth0: entered promiscuous mode
[    2.991540] DSA: tree 0 setup
[    2.993156] clk: Disabling unused clocks

##############################################
***************   FSW-PIXXEL   ***************
***************     IN_xPC     ***************
##############################################
# ip a
1: lo:  mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host proto kernel_lo 
       valid_lft forever preferred_lft forever
2: bond0:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 4e:0a:f0:7b:bc:e0 brd ff:ff:ff:ff:ff:ff
3: can0:  mtu 16 qdisc noop state DOWN group default qlen 10
    link/can 
4: can1:  mtu 16 qdisc noop state DOWN group default qlen 10
    link/can 
5: eth0:  mtu 1536 qdisc noop state DOWN group default qlen 1000
    link/ether 5e:78:8f:24:86:53 brd ff:ff:ff:ff:ff:ff
6: eth1:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 00:04:a3:61:cc:6f brd ff:ff:ff:ff:ff:ff
7: sit0@NONE:  mtu 1480 qdisc noop state DOWN group default qlen 1000
    link/sit 0.0.0.0 brd 0.0.0.0
8: rj45@eth0:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 5e:78:8f:24:86:53 brd ff:ff:ff:ff:ff:ff
9: interswitch@eth0:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 5e:78:8f:24:86:53 brd ff:ff:ff:ff:ff:ff
10: epc2-uplink@eth0:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 5e:78:8f:24:86:53 brd ff:ff:ff:ff:ff:ff
11: t1-1@eth0:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 5e:78:8f:24:86:53 brd ff:ff:ff:ff:ff:ff
12: t1-2@eth0:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 5e:78:8f:24:86:53 brd ff:ff:ff:ff:ff:ff
13: t1-3@eth0:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 5e:78:8f:24:86:53 brd ff:ff:ff:ff:ff:ff
14: t1-4@eth0:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 5e:78:8f:24:86:53 brd ff:ff:ff:ff:ff:ff
15: t1-5@eth0:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 5e:78:8f:24:86:53 brd ff:ff:ff:ff:ff:ff
16: t1-6@eth0:  mtu 1500 qdisc noop state DOWN group default qlen 1000

Current observations:

  • CPU port (SGMII) comes up correctly.
  • I can receive ARP packets from a laptop connected to the RJ45 100BASE-TX port.
  • tcpdump on the board confirms incoming ARP requests from the laptop.
  • When transmitting from the board (ping/arping), the laptop does not receive anything.
  • Laptop tcpdump shows no RX packets from the board.

My questions are:

  1. Is any additional runtime MAC configuration/forwarding / route-table setup required for TX traffic to work correctly on SJA1110 DSA ports?
  2. Is it expected that the 100BASE-T1 PHYs appear only as Generic Clause 45 PHY with this driver tree? Is there a missing dedicated BASE-T1 PHY driver in the current Linux 6.12 Microchip tree?
  3. For testing, I attempted a direct loopback between two T1 ports (t1-1 <-> t1-2) by connecting: (TRX_1_P<->TRX_2_P and TRX_2_P<->TRX_2_N ).

  4. Do the SJA1110 BASE-T1 PHYs require explicit master/slave configuration for link training?

8: rj45@eth0:  mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether 5e:78:8f:24:86:53 brd ff:ff:ff:ff:ff:ff
    inet6 fe80::5c78:8fff:fe24:8653/64 scope link proto kernel_ll 
       valid_lft forever preferred_lft forever
11: t1-1@eth0:  mtu 1500 qdisc noqueue state LOWERLAYERDOWN group default qlen 1000
    link/ether 5e:78:8f:24:86:53 brd ff:ff:ff:ff:ff:ff
    inet 192.168.10.1/24 scope global t1-1
       valid_lft forever preferred_lft forever
12: t1-2@eth0:  mtu 1500 qdisc noqueue state LOWERLAYERDOWN group default qlen 1000
    link/ether 5e:78:8f:24:86:53 brd ff:ff:ff:ff:ff:ff
    inet 192.168.10.2/24 scope global t1-2
       valid_lft forever preferred_lft forever

[  133.739306] macb 20110000.ethernet eth0: configuring for fixed/sgmii link mode
[  133.739364] MACB : HWSTAMP check running
[  133.739414] MACB : HWSTAMP check passed found tsu_clk 
[  133.741036] macb 20110000.ethernet: gem-ptp-timer ptp clock registered.
[  133.742794] sja1105 spi9.0 t1-1: configuring for phy/internal link mode
[  149.008075] sja1105 spi9.0 t1-2: configuring for phy/internal link mode
[  543.849763] sja1105 spi9.0 rj45: configuring for phy/internal link mode
[  545.889486] sja1105 spi9.0 rj45: Link is Up - 100Mbps/Full - flow control off

 

Hardware strap configuration:

  • All PHY_MS pins are strapped LOW (slave mode).
  • PHY_AUTO_MODE = HIGH
  • AUTO_POL_DET = HIGH
  • PHY addresses start from 0x09.

Could the reason for no T1 link be that both PHYs are strapped as SLAVE, and therefore no master clock source exists for link training?

Any guidance regarding:

  • correct T1 bring-up,
  • master/slave configuration,
  • or expected PHY driver support

would be greatly appreciated.


Here is the DTSI that is being used for the Ethernet switch.

/* MAC0 : DSA master into SJA1110A SGMII4 */
&mac0 {
    /delete-property/ phy-handle;
    clocks = <&clkcfg CLK_MAC0>, <&clkcfg CLK_AHB>, <&fabric_fic3_clk>;
    clock-names = "pclk", "hclk", "tsu_clk";
    phy-mode = "sgmii";
    status = "okay";
    dma-noncoherent;
    fixed-link {
        speed = <1000>;
        full-duplex;
    };
};

/*
* SPI9: SJA1110A Host Access Port (HAP)
*   CS0 (reg=0) -> SS0_N -> Switch AP endpoint (DSA driver)
*   CS1 (reg=1) -> SS1_N -> Cortex-M7 uC endpoint (unused)
*
* BOOT_OPTION=11 (serial SPI boot):
*   SJA1110A waits for host config at power-on.
*   DSA driver sends static config tables at probe via CS0.
*   Cortex-M7 is disabled by driver : CS1/SS1 never used.
*
* SPI mode: CPOL=1 CPHA=0 (mode 2) : as per sja1105.yaml
* SPI mode: CPOL=1 CPHA=1 (mode 3) : as per s32gxxxa-rdb.dtsi
*/
&spi9 {
    microchip,motorola-mode = <3>;  /* mode 3: CPOL=1 CPHA=1 */
    num-cs = <2>;
    status = "okay";
    /*
    * SJA1110A : DSA switch (mainline driver)
    * reg=0 -> CS0 -> SS0_N -> switch AP endpoint
    *   ethernet-switch@0 uses reg=<0> (SS0 = switch AP)
    *   sja1110-uc@1 uses reg=<1> (SS1 = uC, disabled here)
    *
    * Port map
    *   port@0  RevMII     Cortex-M7 uC (disabled by driver)
    *   port@1  100BASE-TX RJ45 diagnostic jack
    *   port@2  RGMII2     inter-switch trunk -> SJA port2
    *   port@3  SGMII3     EPC-2 MAC1 relay uplink
    *   port@4  SGMII4     EPC-1 MAC0 CPU port (this board)
    *   Confirm is actual physical address needs to be added here 
    *   port@5  100BASE-T1 TRX_1 (PHY addr 9  on mdio@0)
    *   port@6  100BASE-T1 TRX_2 (PHY addr 10 on mdio@0)
    *   port@7  100BASE-T1 TRX_3 (PHY addr 11 on mdio@0)
    *   port@8  100BASE-T1 TRX_4 (PHY addr 12 on mdio@0)
    *   port@9  100BASE-T1 TRX_5 (PHY addr 13 on mdio@0)
    *   port@a  100BASE-T1 TRX_6 (PHY addr 14 on mdio@0)
    */

    sja1110a: ethernet-switch@0 {
        compatible = "nxp,sja1110a";
        reg = <0>;
        spi-max-frequency = <1000000>;
        interrupt-parent = <&gpio8>;
        interrupts = <9 IRQ_TYPE_LEVEL_LOW>;
    
        mdios {
            #address-cells = <1>;
            #size-cells = <0>;
            mdio_t1: mdio@0 {
                compatible = "nxp,sja1110-base-t1-mdio";
                reg = <0>;
                #address-cells = <1>;
                #size-cells = <0>;
    
                port5_base_t1_phy: ethernet-phy@1 {
                    compatible = "ethernet-phy-ieee802.3-c45";
                    reg = <0x01>;
                };

                port6_base_t1_phy: ethernet-phy@2 {
                    compatible = "ethernet-phy-ieee802.3-c45";
                    reg = <0x02>;
                };

                port7_base_t1_phy: ethernet-phy@3 {
                    compatible = "ethernet-phy-ieee802.3-c45";
                    reg = <0x03>;
                };

                port8_base_t1_phy: ethernet-phy@4 {
                    compatible = "ethernet-phy-ieee802.3-c45";
                    reg = <0x04>;
                };

                port9_base_t1_phy: ethernet-phy@5 {
                    compatible = "ethernet-phy-ieee802.3-c45";
                    reg = <0x05>;
                };

                port10_base_t1_phy: ethernet-phy@6 {
                    compatible = "ethernet-phy-ieee802.3-c45";
                    reg = <0x06>;
                };
            };
    
            mdio_tx: mdio@1 {
                compatible = "nxp,sja1110-base-tx-mdio";
                reg = <1>;
                #address-cells = <1>;
                #size-cells = <0>;
                txphy1: ethernet-phy@1 {
                    reg = <1>;
                };
            };
        };
    
        ethernet-ports {
            #address-cells = <1>;
            #size-cells = <0>;
    
            port@0 { reg = <0>; status = "disabled"; };
    
            /* -------------------------------------
             * RJ45 diagnostic port
             * ------------------------------------- */
            port@1 {
                reg = <1>;
                label = "rj45";
                phy-mode = "internal";
                phy-handle = <&txphy1>;
            };
    
            port@2 {
                reg = <2>;
                label = "interswitch";
                phy-mode = "rgmii";
                rx-internal-delay-ps = <0>;
                tx-internal-delay-ps = <0>;
                fixed-link { speed = <1000>; full-duplex; };
            };
    
            port@3 {
                reg = <3>;
                label = "epc2-uplink";
                phy-mode = "sgmii";
                fixed-link { speed = <1000>; full-duplex; };
            };
    
            /* -------------------------------------
             * CPU port
             * MAC0 <-> SGMII4 <-> port4
             * ------------------------------------- */
            port@4 {
                reg = <4>;
                label = "cpu";
                ethernet = <&mac0>;
                phy-mode = "sgmii";
                fixed-link {
                    speed = <1000>;
                    full-duplex;
                };
            };
    
            port@5 {
                reg = <5>;
                label = "t1-1";
                phy-mode = "internal"; 
                phy-handle = <&port5_base_t1_phy>;
            };

            port@6 {
                reg = <6>; 
                label = "t1-2";
                phy-mode = "internal"; 
                phy-handle = <&port6_base_t1_phy>;
            };

            port@7 {
                reg = <7>; 
                label = "t1-3";
                phy-mode = "internal"; 
                phy-handle = <&port7_base_t1_phy>;
            };

            port@8 {
                reg = <8>; 
                label = "t1-4";
                phy-mode = "internal"; 
                phy-handle = <&port8_base_t1_phy>;
            };

            port@9 {
                reg = <9>; 
                label = "t1-5";
                phy-mode = "internal"; 
                phy-handle = <&port9_base_t1_phy>;
            };

            port@a {
                reg = <10>; 
                label = "t1-6";
                phy-mode = "internal"; 
                phy-handle = <&port10_base_t1_phy>;
            };
        };
    };

    /* SPIDEV for testing SPI lines using CS1 lines*/
    sja110_spidev: spidev@1 {
        compatible = "microchip,mpfs-spidev";
        reg = <1>;
        status = "okay";
        spi-max-frequency = <1000000>;
    };
};

 
-- Ankur

Re: SJA1110A DSA bring UP : 100BASE-TX TX failure and T1 link training issues

Hello @Ankur_pixl ,

Thank you for sharing all details at once.

Please find answers to your question below.

Q1. Is any additional runtime MAC configuration/forwarding / route-table setup required for TX traffic to work correctly on SJA1110 DSA ports?

A1. Yes, please find it below.

Q2. Is it expected that the 100BASE-T1 PHYs appear only as Generic Clause 45 PHY with this driver tree? Is there a missing dedicated BASE-T1 PHY driver in the current Linux 6.12 Microchip tree?

A2. No.

Q3. For testing, I attempted a direct loopback between two T1 ports (t1-1 <-> t1-2) by connecting: (TRX_1_P<->TRX_2_P and TRX_2_P<->TRX_2_N ).

A3: Yes, that's correct.

Q4. Do the SJA1110 BASE-T1 PHYs require explicit master/slave configuration for link training?

A4. Yes, 100BASE-T1 requires explicit Master/Slave settings. FYI, option "AUTO" in a driver usually means "follow pin strapping". For a valid link, one PHY must be configured as MASTER and the other as SLAVE, either via hardware strapping or PHY configuration.



From your logs and DT, the switch initialization and PHY binding look correct.

The behavior, where RX works but TX does not, is expected if no bridge is configured in Linux. In DSA, traffic is not forwarded automatically between the CPU port and user ports. DSA switch behaves like a hardware switch, but Linux does not enable forwarding between ports unless a bridge or VLAN configuration is explicitly created.

Please create a bridge and attach both the CPU port (eth0) and the user port (rj45):

ip link set eth0 up
ip link set rj45 up

ip link add br0 type bridge
ip link set br0 up
ip link set eth0 master br0
ip link set rj45 master br0

ip addr add 192.168.1.2/24 dev br0


Best regards,

Pavel

Re: SJA1110A DSA bring UP : 100BASE-TX TX failure and T1 link training issues

Hi,

I tried doing the same, but still don't see any packets being received by the laptop from the
board. Below are the exact steps I followed:

-------------------
ip link set eth0 up
ip link set rj45 up
ip link add br0 type bridge
ip link set br0 type bridge
ip link set br0 up
ip link set rj45 master br0
ip addr add 192.168.1.1/24 dev br0
ping 192.168.1.2

-------------------

To give more context: the RJ45 connector had rework done, where the P/N ports of the TX pair from the chip were connected incorrectly to the RJ45, which could also be contributing to the issue. However, the link always comes UP.

Is there anything I'm missing? I've attached the kernel config related to ETH and PHY. Please check if anything is missing there.

# ------------------------------
# Networking / HSR / QoS / PTP
# ------------------------------
CONFIG_HSR=y
CONFIG_PTP_1588_CLOCK=y
CONFIG_POSIX_TIMERS=y
CONFIG_BONDING=y
CONFIG_NET_SCHED=y
CONFIG_NET_SCH_FIFO=y
CONFIG_NET_SCH_HTB=y
CONFIG_NET_SCH_FQ_CODEL=y
CONFIG_NET_SCH_MQPRIO=y
CONFIG_NET_SCH_ETF=y
CONFIG_NET_SCH_TAPRIO=y
CONFIG_NET_CLS=y
CONFIG_NET_CLS_U32=y
CONFIG_NET_ACT_MIRRED=y
CONFIG_MACB_USE_HWSTAMP=y
CONFIG_NETWORK_PHY_TIMESTAMPING=y

# -----------------------------
# SJA1110 Ethernet Switch support
# -----------------------------
CONFIG_PHYLINK=y
CONFIG_PCS_MARVELL=y
CONFIG_SWPHY=y
CONFIG_BRIDGE_VLAN_FILTERING=y
CONFIG_VLAN_8021Q=y
CONFIG_NET_DSA=y
CONFIG_NET_DSA_TAG_8021Q=y
CONFIG_NET_DSA_SJA1105=y
CONFIG_NET_DSA_SJA1105_PTP=y
CONFIG_NET_DSA_SJA1105_TAS=y
CONFIG_NET_SWITCHDEV=y
CONFIG_NET_DSA_TAG_OCELOT_8021Q=y
CONFIG_MDIO_BUS=y                
CONFIG_MDIO_DEVICE=y             
CONFIG_NET_SCH_CBS=y             
CONFIG_BRIDGE=y
CONFIG_OF_MDIO=y
CONFIG_MDIO_DEVRES=y
CONFIG_NET_DSA_SJA1105_VL=y
CONFIG_PHYLIB_10G=y

# -----------------------------
# PHY support for direct ETH link (MAC0 - OBC)
# Fixed link - no PHY driver needed for MAC0
# MAC1 - SJA1110 also uses fixed link to switch CPU port
# -----------------------------
CONFIG_FIXED_PHY=y
CONFIG_PHYLIB=y
CONFIG_NXP_CBTX_PHY=y
CONFIG_NXP_C45_TJA11XX_PHY=y
CONFIG_NXP_TJA11XX_PHY=y
CONFIG_MARVELL_88Q2XXX_PHY=y
CONFIG_AQUANTIA_PHY=y
CONFIG_MICREL_PHY=y


I also tried a 100BASE-T1 loopback with T1-1 and T1-2, setting T1-1 as PHY_MS = 1 (master) and T1-2 as PHY_MS = 0 (slave). I brought up both interfaces, but the link never came up. Is that expected? What am I missing? The loopback is a simple wired connection on the twisted pairs (P/N).

-------------------

ip link set eth0 up
ip link set rj45 up
ip link set t1-1 up
ip link set t1-2 up


-------------------

Re: SJA1110A DSA bring UP : 100BASE-TX TX failure and T1 link training issues

Hello @Ankur_pixl ,

somehow you missed a row:

    ip link set eth0 up
    ip link set rj45 up

 

    ip link add br0 type bridge
    ip link set br0 up

 

    ip link set eth0 master br0
    ip link set rj45 master br0

 

    ip addr add 192.168.1.1/24 dev br


Kernel config appears to be correct.

Regarding T1

The simple wiring connection on 100BASE-T1 should work - I use that all the time. Do you use PHY_ADDR* pin strapping?

Please share:
ethtool t1-1
ethtool t1-2
dmesg | grep -iE "t1-|phy|sja1105" after bringing the links up


Best regards,

Pavel

Re: SJA1110A DSA bring UP : 100BASE-TX TX failure and T1 link training issues

Hello @PavelL ,
Thanks for the answers.

After attaching eth0 to br0 when trying to attach rj45 i see the error as below.

#  ip link set eth0 up
[   20.561460] macb 20110000.ethernet eth0: configuring for fixed/sgmii link mode
[   20.561554] MACB : HWSTAMP check running
# [   20.561605] MACB : HWSTAMP check passed found tsu_clk 
[   20.562612] macb 20110000.ethernet: gem-ptp-timer ptp clock registered.
 ip link set rj45 up
# [   25.693665] sja1105 spi9.0 rj45: configuring for phy/internal link mode
[   27.746002] sja1105 spi9.0 rj45: Link is Up - 100Mbps/Full - flow control off
# ip link add br0 type bridge
# ip link set br0 up
# ip link set eth0 master br0
# [   43.053547] br0: port 1(eth0) entered blocking state
[   43.053590] br0: port 1(eth0) entered disabled state
[   43.053666] macb 20110000.ethernet eth0: entered allmulticast mode
ip link set rj45 master br0
[   49.972011] br0: port 2(rj45) entered blocking state
[   49.972214] br0: port 2(rj45) entered disabled state
[   49.972288] sja1105 spi9.0 rj45: entered allmulticast mode
RTNETLINK answer[   50.005003] sja1105 spi9.0 rj45: left allmulticast mode
s: Invalid argument



On the T1 port, please find the response below

# ip link set eth0 up
[  305.486294] macb 20110000.ethernet eth0: configuring for fixed/sgmii link mode
[  305.486405] MACB : HWSTAMP check running
[  305.486456] MACB : HWSTAMP check passed found tsu_clk 
[  305.487476] macb 20110000.ethernet: gem-ptp-timer ptp clock registered.
# ip link set rj45 up
# [  311.277622] sja1105 spi9.0 rj45: configuring for phy/internal link mode
[  313.313486] sja1105 spi9.0 rj45: Link is Up - 100Mbps/Full - flow control off
# ip link set t1-1 up
# [  326.282210] sja1105 spi9.0 t1-1: configuring for phy/internal link mode
# ip link set t1-2 up
[  330.126681] sja1105 spi9.0 t1-2: configuring for phy/internal link mode
# ethtool t1-1
Settings for t1-1:
        Supported ports: [ ]
        Supported link modes:   100baseT1/Full 
        Supported pause frame use: No
        Supports auto-negotiation: No
        Supported FEC modes: Not reported
        Advertised link modes:  100baseT1/Full 
        Advertised pause frame use: No
        Advertised auto-negotiation: No
        Advertised FEC modes: Not reported
        Speed: 100Mb/s
        Duplex: Full
        Port: MII
        PHYAD: 1
        Transceiver: external
        Auto-negotiation: off
        Supports Wake-on: d
        Wake-on: d
        Link detected: no
# ethtool t1-2
Settings for t1-2:
        Supported ports: [ ]
        Supported link modes:   100baseT1/Full 
        Supported pause frame use: No
        Supports auto-negotiation: No
        Supported FEC modes: Not reported
        Advertised link modes:  100baseT1/Full 
        Advertised pause frame use: No
        Advertised auto-negotiation: No
        Advertised FEC modes: Not reported
        Speed: 100Mb/s
        Duplex: Full
        Duplex: Full                                                                                                        
        Port: MII                                                                                                           
        PHYAD: 2                                                                                                            
        Transceiver: external                                                                                               
        Auto-negotiation: off                                                                                               
        Wake-on: d
        Link detected: no
# [  365.547745] power_supply bq34z100-0: driver failed to report `time_to_empty_avg' property: -22
dmesg | grep -iE "t1-|phy|sja1105" 
[    2.250188] u-dma-buf udmabuf-ddr-c0: phys address   = 0x0000000088000000
[    2.995658] u-dma-buf udmabuf-ddr-nc0: phys address   = 0x00000000c8000000
[    3.012712] u-dma-buf udmabuf-ddr-nc-wcb0: phys address   = 0x00000000d8000000
[    3.081775] sja1105 spi9.0: Probed switch chip: SJA1110A
[    3.081796] sja1105 spi9.0: max_xfer_len = 256 bytes
[    3.233399] sja1105 spi9.0: Probed switch chip: SJA1110A
[    3.233418] sja1105 spi9.0: max_xfer_len = 256 bytes
[    3.236047] sja1105 spi9.0: Config buffer length: 1776 bytes
[    3.236072] sja1105 spi9.0: Config buffer device_id at offset 0: 0x0f0300b7
[    3.429135] sja1105 status decoded: CONFIGS=1 CRCCHKL=0 IDS=0 CRCCHKG=0 NSLOT=5
[    3.429165] sja1105 spi9.0: sja1105_static_config_load done
[    3.429181] sja1105 spi9.0: sja1105_clocking done
[    3.429194] sja1105 spi9.0: sja1105_TAS and flower setup done
[    3.430339] sja1105 spi9.0: sja1105_ptp_clock_register done
[    3.572901] sja1105 spi9.0: sja1105_mdiobus_register done
[    3.572938] sja1105 spi9.0: sja1105_devlink_setup done
[    3.586915] sja1105 spi9.0: dsa_tag_8021q_register and rtnl_unlockdone
[    3.588440] sja1105 spi9.0: configuring for fixed/sgmii link mode
[    3.593936] sja1105 spi9.0: Link is Up - 1Gbps/Full - flow control off
[    3.652480] sja1105 spi9.0 rj45 (uninitialized): PHY [spi9.0-base-tx:01] driver [NXP CBTX (SJA1110)] (irq=POLL)
[    3.661033] sja1105 spi9.0 t1-1 (uninitialized): PHY [spi9.0-base-t1:01] driver [Generic Clause 45 PHY] (irq=POLL)
[    3.664058] sja1105 spi9.0 t1-2 (uninitialized): PHY [spi9.0-base-t1:02] driver [Generic Clause 45 PHY] (irq=POLL)
[    3.667342] sja1105 spi9.0 t1-3 (uninitialized): PHY [spi9.0-base-t1:03] driver [Generic Clause 45 PHY] (irq=POLL)
[    3.670592] sja1105 spi9.0 t1-4 (uninitialized): PHY [spi9.0-base-t1:04] driver [Generic Clause 45 PHY] (irq=POLL)
[    3.673818] sja1105 spi9.0 t1-5 (uninitialized): PHY [spi9.0-base-t1:05] driver [Generic Clause 45 PHY] (irq=POLL)
[    3.676972] sja1105 spi9.0 t1-6 (uninitialized): PHY [spi9.0-base-t1:06] driver [Generic Clause 45 PHY] (irq=POLL)
[  311.277622] sja1105 spi9.0 rj45: configuring for phy/internal link mode
[  313.313486] sja1105 spi9.0 rj45: Link is Up - 100Mbps/Full - flow control off
[  326.282210] sja1105 spi9.0 t1-1: configuring for phy/internal link mode
[  330.126681] sja1105 spi9.0 t1-2: configuring for phy/internal link mode

 
Yes, I do use PHY_ADDR strapping, with the PHY_ADDR[4:0] set as 5'b010001. ( 0x09 to 0x14 ) same as in the https://github.com/nxp-auto-linux/linux/blob/810f396375526c11989bd1a296d2f9959de9392f/arch/arm64/boo... and the S32G-VNP-RDB3 schematics. 

Ankur_pixl_0-1779443722982.png

-- Ankur 


Re: SJA1110A DSA bring UP : 100BASE-TX TX failure and T1 link training issues

Hello @Ankur_pixl ,

Thanks for the update - at this point I think it’s best that we restart the debug from scratch with a minimal, deterministic setup, because we now have a few interacting variables (DSA topology, bridge behavior and PHY access paths) and we need to isolate whether the RJ45 issue is software (Linux/DSA/bridge/VLAN) or hardware (TX pair / magnetics).
From your original description we have a clear symptom pattern:

  • RJ45 RX works (you can see ARP requests arriving from the laptop).
  • RJ45 TX does not (laptop sees no frames from the board).
  • 100BASE‑T1 is still down and right now we don’t have enough evidence to conclude whether this is configuration/management-path related or a physical-layer/training issue.

Here's the 1st step:

Step 1 - Confirm basic TX on RJ45 without any bridge

ip link set eth0 up
ip link set rj45 up

 

# IMPORTANT: remove IPs from other devices to avoid confusing routing
ip addr flush dev eth0
ip addr flush dev rj45
ip addr flush dev br0 2>/dev/null

 

# Put IP directly on the RJ45 DSA port
ip addr add 192.168.1.1/24 dev rj45

 

# Show routes and addresses for sanity
ip addr show rj45
ip route show

 

# Generate traffic
arping -I rj45 192.168.1.2
ping   -I rj45 192.168.1.2

At the same time, capture on the board
tcpdump -i rj45 -e -nn arp or icmp

On the laptop
tcpdump -i -e -nn arp or icmp

Best regards,

Pavel

Re: SJA1110A DSA bring UP : 100BASE-TX TX failure and T1 link training issues

Hello, 

I also see that the eth0 link doesn't show RUNNING, can that be one of the problems? And when doing PING, the RJ45 txbytes increase, but the eth0 sends all those to be dropped.

eth0      Link encap:Ethernet  HWaddr 92:56:D3:62:3D:60  
          UP BROADCAST MULTICAST  MTU:1536  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:10 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:33 

rj45      Link encap:Ethernet  HWaddr 92:56:D3:62:3D:60  
          inet6 addr: fe80::9056:d3ff:fe62:3d60/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:10 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:796 (796.0 B)


# ip a
1: lo:  mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host proto kernel_lo 
       valid_lft forever preferred_lft forever
2: bond0:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether ee:06:ea:10:7f:d4 brd ff:ff:ff:ff:ff:ff
3: can0:  mtu 16 qdisc noop state DOWN group default qlen 10
    link/can 
4: can1:  mtu 16 qdisc noop state DOWN group default qlen 10
    link/can 
5: eth0:  mtu 1536 qdisc mq state DOWN group default qlen 1000
    link/ether 92:56:d3:62:3d:60 brd ff:ff:ff:ff:ff:ff
6: eth1:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 00:04:a3:61:cc:6f brd ff:ff:ff:ff:ff:ff
7: sit0@NONE:  mtu 1480 qdisc noop state DOWN group default qlen 1000
    link/sit 0.0.0.0 brd 0.0.0.0
8: rj45@eth0:  mtu 1500 qdisc noqueue master br0 state UP group default qlen 1000
    link/ether 92:56:d3:62:3d:60 brd ff:ff:ff:ff:ff:ff
    inet6 fe80::9056:d3ff:fe62:3d60/64 scope link proto kernel_ll 
       valid_lft forever preferred_lft forever
9: interswitch@eth0:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 92:56:d3:62:3d:60 brd ff:ff:ff:ff:ff:ff
10: epc2-uplink@eth0:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 92:56:d3:62:3d:60 brd ff:ff:ff:ff:ff:ff
11: t1-1@eth0:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 92:56:d3:62:3d:60 brd ff:ff:ff:ff:ff:ff
12: t1-2@eth0:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 92:56:d3:62:3d:60 brd ff:ff:ff:ff:ff:ff
13: t1-3@eth0:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 92:56:d3:62:3d:60 brd ff:ff:ff:ff:ff:ff
14: t1-4@eth0:  mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 92:56:d3:62:3d:60 brd ff:ff:ff:ff:ff:ff
15: t1-5@eth0:  mtu 1500 qdisc noqueue master br0 state LOWERLAYERDOWN group default qlen 1000
    link/ether 92:56:d3:62:3d:60 brd ff:ff:ff:ff:ff:ff
16: t1-6@eth0:  mtu 1500 qdisc noqueue master br0 state LOWERLAYERDOWN group default qlen 1000
    link/ether 92:56:d3:62:3d:60 brd ff:ff:ff:ff:ff:ff
17: br0:  mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether 92:56:d3:62:3d:60 brd ff:ff:ff:ff:ff:ff
    inet 192.168.10.1/24 scope global br0
       valid_lft forever preferred_lft forever
    inet6 fe80::9056:d3ff:fe62:3d60/64 scope link proto kernel_ll 
       valid_lft forever preferred_lft forever

 -- Ankur 

Re: SJA1110A DSA bring UP : 100BASE-TX TX failure and T1 link training issues

Hello @PavelL 

Even after bridge creation, I see that none of the bytes are leaving the switch.

# ip link set eth0 up
[   78.263728] macb 20110000.ethernet eth0: configuring for fixed/sgmii link mode
[   78.263859] MACB : HWSTAMP check running
# [   78.263911] MACB : HWSTAMP check passed found tsu_clk 
[   78.265094] macb 20110000.ethernet: gem-ptp-timer ptp clock registered.
ip addr flush dev rj45                                                       
# ip link add name br0 type bridge                                                                                    
# ip link set br0 type bridge vlan_filtering 0                                                                        
# ip link set rj45 master br0                                                                                         
[  119.331341] br0: port 1(rj45) entered blocking state                                                               
[  119.331506] br0: port 1(rj45) entered disabled state
[  119.331588] sja1105 spi9.0 rj45: entered allmulticast mode
# [  119.331615] macb 20110000.ethernet eth0: entered allmulticast mode
[  119.339852] sja1105 spi9.0 rj45: entered promiscuous mode
ip addr add 192.168.1.1/24 dev br0
# ip link set rj45 up
# [  130.485390] sja1105 spi9.0 rj45: configuring for phy/internal link mode
[  132.518207] sja1105 spi9.0 rj45: Link is Up - 100Mbps/Full - flow control off
ip link set br0 up
# [  137.057392] br0: port 1(rj45) entered blocking state
[  137.057430] br0: port 1(rj45) entered forwarding state
# ethtool -S rj45 | grep -E "n_txfrm|n_rxfrm|n_not_reach"
     n_rxfrm: 7
     n_txfrm: 0
     n_not_reach: 7
# ping -c 5 -I br0 192.168.1.2
PING 192.168.1.2 (192.168.1.2): 56 data bytes
--- 192.168.1.2 ping statistics ---
5 packets transmitted, 0 packets received, 100% packet loss
# ethtool -S rj45 | grep -E "n_txfrm|n_rxfrm|n_not_reach"
     n_rxfrm: 14
     n_txfrm: 0
     n_not_reach: 14

 
Is this some config problem? 

-- Ankur 

Re: SJA1110A DSA bring UP : 100BASE-TX TX failure and T1 link training issues

Hello,

1.) I tried testing the same and also checked a few other things to validate the problem. It looks like there is no L2 forwarding path programmed between the CPU port (p04) and RJ45.

Here is the entire log 

////////////////// AFTER BOOT  //////////////////
# ethtool -S eth0
NIC statistics:
     tx_octets: 0
     tx_frames: 0
     tx_broadcast_frames: 0
     tx_multicast_frames: 0
     tx_pause_frames: 0
     tx_64_byte_frames: 0
     tx_65_127_byte_frames: 0
     tx_128_255_byte_frames: 0
     tx_256_511_byte_frames: 0
     tx_512_1023_byte_frames: 0
     tx_1024_1518_byte_frames: 0
     tx_greater_than_1518_byte_frames: 0
     tx_underrun: 0
     tx_single_collision_frames: 0
     tx_multiple_collision_frames: 0
     tx_excessive_collisions: 0
     tx_late_collisions: 0
     tx_deferred_frames: 0
     tx_carrier_sense_errors: 0
     rx_octets: 0
     rx_frames: 0
     rx_broadcast_frames: 0
     rx_multicast_frames: 0
     rx_pause_frames: 0
     rx_64_byte_frames: 0
     rx_65_127_byte_frames: 0
     rx_128_255_byte_frames: 0
     rx_256_511_byte_frames: 0
     rx_512_1023_byte_frames: 0
     rx_1024_1518_byte_frames: 0
     rx_greater_than_1518_byte_frames: 0
     rx_undersized_frames: 0
     rx_oversize_frames: 0
     rx_jabbers: 0
     rx_frame_check_sequence_errors: 0
     rx_length_field_frame_errors: 0
     rx_symbol_errors: 0
     rx_alignment_errors: 0
     rx_resource_errors: 0
     rx_overruns: 0
     rx_ip_header_checksum_errors: 0
     rx_tcp_checksum_errors: 0
     rx_udp_checksum_errors: 0
     q0_rx_packets: 0
     q0_rx_bytes: 0
     q0_rx_dropped: 0
     q0_tx_packets: 0
     q0_tx_bytes: 0
     q0_tx_dropped: 0
     q1_rx_packets: 0
     q1_rx_bytes: 0
     q1_rx_dropped: 0
     q1_tx_packets: 0
     q1_tx_bytes: 0
     q1_tx_dropped: 0
     q2_rx_packets: 0
     q2_rx_bytes: 0
     q2_rx_dropped: 0
     q2_tx_packets: 0
     q2_tx_bytes: 0
     q2_tx_dropped: 0
     q3_rx_packets: 0
     q3_rx_bytes: 0
     q3_rx_dropped: 0
     q3_tx_packets: 0
     q3_tx_bytes: 0
     q3_tx_dropped: 0
     p04_: 0
     p04_n_runt: 0
     p04_n_soferr: 0
     p04_n_alignerr: 0
     p04_n_miierr: 0
     p04_typeerr: 0
     p04_sizeerr: 0
     p04_tctimeout: 0
     p04_priorerr: 0
     p04_nomaster: 0
     p04_memov: 0
     p04_memerr: 0
     p04_invtyp: 0
     p04_intcyov: 0
     p04_domerr: 0
     p04_pcfbagdrop: 0
     p04_spcprior: 0
     p04_ageprior: 0
     p04_portdrop: 0
     p04_lendrop: 0
     p04_bagdrop: 0
     p04_policeerr: 0
     p04_drpnona664err: 0
     p04_spcerr: 0
     p04_agedrp: 0
     p04_n_n664err: 0
     p04_n_vlanerr: 0
     p04_n_unreleased: 0
     p04_n_sizeerr: 0
     p04_n_crcerr: 0
     p04_n_vlnotfound: 0
     p04_n_ctpolerr: 0
     p04_n_polerr: 0
     p04_n_rxfrm: 0
     p04_n_rxbyte: 0
     p04_n_txfrm: 0
     p04_n_txbyte: 0
     p04_n_qfull: 0
     p04_n_part_drop: 0
     p04_n_egr_disabled: 0
     p04_n_not_reach: 0
     p04_n_drops_nolearn: 0
     p04_n_drops_noroute: 0
     p04_n_drops_ill_dtag: 0
     p04_n_drops_dtag: 0
     p04_n_drops_sotag: 0
     p04_n_drops_sitag: 0
     p04_n_drops_utag: 0
     p04_n_tx_bytes_1024_2047: 0
     p04_n_tx_bytes_512_1023: 0
     p04_n_tx_bytes_256_511: 0
     p04_n_tx_bytes_128_255: 0
     p04_n_tx_bytes_65_127: 0
     p04_n_tx_bytes_64: 0
     p04_n_tx_mcast: 0
     p04_n_tx_bcast: 0
     p04_n_rx_bytes_1024_2047: 0
     p04_n_rx_bytes_512_1023: 0
     p04_n_rx_bytes_256_511: 0
     p04_n_rx_bytes_128_255: 0
     p04_n_rx_bytes_65_127: 0
     p04_n_rx_bytes_64: 0
     p04_n_rx_mcast: 0
# ethtool -S rj45
NIC statistics:
     tx_packets: 0
     tx_bytes: 0
     rx_packets: 0
     rx_bytes: 0
     : 0
     n_runt: 0
     n_soferr: 0
     n_alignerr: 0
     n_miierr: 0
     typeerr: 0
     sizeerr: 0
     tctimeout: 0
     priorerr: 0
     nomaster: 0
     memov: 0
     memerr: 0
     invtyp: 0
     intcyov: 0
     domerr: 0
     pcfbagdrop: 0
     spcprior: 0
     ageprior: 0
     portdrop: 0
     lendrop: 0
     bagdrop: 0
     policeerr: 0
     drpnona664err: 0
     spcerr: 0
     agedrp: 0
     n_n664err: 0
     n_vlanerr: 0
     n_unreleased: 0
     n_sizeerr: 0
     n_crcerr: 0
     n_vlnotfound: 0
     n_ctpolerr: 0                                                                                                    
     n_polerr: 0                                                                                                      
     n_rxfrm: 0                                                                                                       
     n_rxbyte: 0                                                                                                      
     n_txfrm: 0                                                                                                       
     n_txbyte: 0
     n_qfull: 0
     n_part_drop: 0
     n_egr_disabled: 0
     n_not_reach: 0
     n_drops_nolearn: 0
     n_drops_noroute: 0
     n_drops_ill_dtag: 0
     n_drops_dtag: 0
     n_drops_sotag: 0
     n_drops_sitag: 0
     n_drops_utag: 0
     n_tx_bytes_1024_2047: 0
     n_tx_bytes_512_1023: 0
     n_tx_bytes_256_511: 0
     n_tx_bytes_128_255: 0
     n_tx_bytes_65_127: 0
     n_tx_bytes_64: 0
     n_tx_mcast: 0
     n_tx_bcast: 0
     n_rx_bytes_1024_2047: 0
     n_rx_bytes_512_1023: 0
     n_rx_bytes_256_511: 0
     n_rx_bytes_128_255: 0
     n_rx_bytes_65_127: 0
     n_rx_bytes_64: 0
     n_rx_mcast: 0
////////////////// Link UP //////////////////
# ip link set eth0 up
[   69.576075] macb 20110000.ethernet eth0: configuring for fixed/sgmii link mode
[   69.576204] MACB : HWSTAMP check running
# [   69.576257] MACB : HWSTAMP check passed found tsu_clk 
[   69.577736] macb 20110000.ethernet: gem-ptp-timer ptp clock registered.
# ip link set rj45 up
# [   73.786469] sja1105 spi9.0 rj45: configuring for phy/internal link mode
[   75.841723] sja1105 spi9.0 rj45: Link is Up - 100Mbps/Full - flow control off
# ip addr add 192.168.1.1/24 dev rj45
# ip link set rj45 up
# ip addr show rj45
8: rj45@eth0:  mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether e6:e8:ae:30:6b:84 brd ff:ff:ff:ff:ff:ff
    inet 192.168.1.1/24 scope global rj45
       valid_lft forever preferred_lft forever
    inet6 fe80::e4e8:aeff:fe30:6b84/64 scope link proto kernel_ll 
       valid_lft forever preferred_lft forever
# ethtool -S rj45
NIC statistics:
     tx_packets: 10
     tx_bytes: 796
     rx_packets: 0
     rx_bytes: 0
     : 0
     n_runt: 0
     n_soferr: 0
     n_alignerr: 0
     n_miierr: 0
     typeerr: 0
     sizeerr: 0
     tctimeout: 0
     priorerr: 0
     nomaster: 0
     memov: 0
     memerr: 0
     invtyp: 0
     intcyov: 0
     domerr: 0
     pcfbagdrop: 0
     spcprior: 0
     ageprior: 0
     portdrop: 0
     lendrop: 0
     bagdrop: 0
     policeerr: 0
     drpnona664err: 0
     spcerr: 0
     agedrp: 0
     n_n664err: 0
     n_vlanerr: 0
     n_unreleased: 0
     n_sizeerr: 0
     n_crcerr: 0
     n_vlnotfound: 0
     n_ctpolerr: 0
     n_polerr: 0
     n_rxfrm: 8
     n_rxbyte: 1690
     n_txfrm: 0
     n_txbyte: 0
     n_qfull: 0
     n_part_drop: 0
     n_egr_disabled: 0
     n_not_reach: 8
     n_drops_nolearn: 0
     n_drops_noroute: 0
     n_drops_ill_dtag: 0
     n_drops_dtag: 0
     n_drops_sotag: 0
     n_drops_sitag: 0
     n_drops_utag: 0
     n_tx_bytes_1024_2047: 0
     n_tx_bytes_512_1023: 0
     n_tx_bytes_256_511: 0
     n_tx_bytes_128_255: 0
     n_tx_bytes_65_127: 0
     n_tx_bytes_64: 0
     n_tx_mcast: 0
     n_tx_bcast: 0
     n_rx_bytes_1024_2047: 0
     n_rx_bytes_512_1023: 2
     n_rx_bytes_256_511: 0
     n_rx_bytes_128_255: 0
     n_rx_bytes_65_127: 0
     n_rx_bytes_64: 6
     n_rx_mcast: 8
# ethtool -S eth0
NIC statistics:
     tx_octets: 0
     tx_frames: 0
     tx_broadcast_frames: 0
     tx_multicast_frames: 0
     tx_pause_frames: 0
     tx_64_byte_frames: 0
     tx_65_127_byte_frames: 0
     tx_128_255_byte_frames: 0
     tx_256_511_byte_frames: 0
     tx_512_1023_byte_frames: 0
     tx_1024_1518_byte_frames: 0
     tx_greater_than_1518_byte_frames: 0
     tx_underrun: 0
     tx_single_collision_frames: 0
     tx_multiple_collision_frames: 0
     tx_excessive_collisions: 0
     tx_late_collisions: 0
     tx_deferred_frames: 0
     tx_carrier_sense_errors: 0
     rx_octets: 0
     rx_frames: 0
     rx_broadcast_frames: 0
     rx_multicast_frames: 0
     rx_pause_frames: 0
     rx_64_byte_frames: 0
     rx_65_127_byte_frames: 0
     rx_128_255_byte_frames: 0
     rx_256_511_byte_frames: 0
     rx_512_1023_byte_frames: 0
     rx_1024_1518_byte_frames: 0
     rx_greater_than_1518_byte_frames: 0
     rx_undersized_frames: 0
     rx_oversize_frames: 0
     rx_jabbers: 0
     rx_frame_check_sequence_errors: 0
     rx_length_field_frame_errors: 0
     rx_symbol_errors: 0
     rx_alignment_errors: 0
     rx_resource_errors: 0
     rx_overruns: 0
     rx_ip_header_checksum_errors: 0
     rx_tcp_checksum_errors: 0
     rx_udp_checksum_errors: 0
     q0_rx_packets: 0
     q0_rx_bytes: 0
     q0_rx_dropped: 0
     q0_tx_packets: 0
     q0_tx_bytes: 0
     q0_tx_dropped: 0
     q1_rx_packets: 0
     q1_rx_bytes: 0
     q1_rx_dropped: 0
     q1_tx_packets: 0
     q1_tx_bytes: 0
     q1_tx_dropped: 0
     q2_rx_packets: 0
     q2_rx_bytes: 0
     q2_rx_dropped: 0
     q2_tx_packets: 0
     q2_tx_bytes: 0
     q2_tx_dropped: 0
     q3_rx_packets: 0
     q3_rx_bytes: 0
     q3_rx_dropped: 0
     q3_tx_packets: 0
     q3_tx_bytes: 0
     q3_tx_dropped: 0
     p04_: 0
     p04_n_runt: 0
     p04_n_soferr: 0
     p04_n_alignerr: 0
     p04_n_miierr: 0
     p04_typeerr: 0
     p04_sizeerr: 0
     p04_tctimeout: 0
     p04_priorerr: 0
     p04_nomaster: 0
     p04_memov: 0
     p04_memerr: 0
     p04_invtyp: 0
     p04_intcyov: 0
     p04_domerr: 0
     p04_pcfbagdrop: 0
     p04_spcprior: 0
     p04_ageprior: 0
     p04_portdrop: 0
     p04_lendrop: 0
     p04_bagdrop: 0
     p04_policeerr: 0
     p04_drpnona664err: 0
     p04_spcerr: 0
     p04_agedrp: 0
     p04_n_n664err: 0
     p04_n_vlanerr: 0
     p04_n_unreleased: 0
     p04_n_sizeerr: 0
     p04_n_crcerr: 0
     p04_n_vlnotfound: 0
     p04_n_ctpolerr: 0
     p04_n_polerr: 0
     p04_n_rxfrm: 0
     p04_n_rxbyte: 0
     p04_n_txfrm: 8
     p04_n_txbyte: 1722
     p04_n_qfull: 0
     p04_n_part_drop: 0
     p04_n_egr_disabled: 0
     p04_n_not_reach: 0
     p04_n_drops_nolearn: 0
     p04_n_drops_noroute: 0
     p04_n_drops_ill_dtag: 0
     p04_n_drops_dtag: 0
     p04_n_drops_sotag: 0
     p04_n_drops_sitag: 0
     p04_n_drops_utag: 0
     p04_n_tx_bytes_1024_2047: 0
     p04_n_tx_bytes_512_1023: 2
     p04_n_tx_bytes_256_511: 0
     p04_n_tx_bytes_128_255: 0
     p04_n_tx_bytes_65_127: 6
     p04_n_tx_bytes_64: 0
     p04_n_tx_mcast: 8
     p04_n_tx_bcast: 0
     p04_n_rx_bytes_1024_2047: 0
     p04_n_rx_bytes_512_1023: 0
     p04_n_rx_bytes_256_511: 0
     p04_n_rx_bytes_128_255: 0
     p04_n_rx_bytes_65_127: 0
     p04_n_rx_bytes_64: 0
     p04_n_rx_mcast: 0
////////////////// PING BOARD TO Laptop //////////////////
# arping -I rj45 192.168.1.2
ARPING 192.168.1.2 from 192.168.1.1 rj45
^CSent 9 probe(s) (9 broadcast(s))
Received 0 response(s) (0 request(s), 0 broadcast(s))
# ethtool -S eth0
NIC statistics:
     tx_octets: 0
     tx_frames: 0
     tx_broadcast_frames: 0
     tx_multicast_frames: 0
     tx_pause_frames: 0
     tx_64_byte_frames: 0
     tx_65_127_byte_frames: 0
     tx_128_255_byte_frames: 0
     tx_256_511_byte_frames: 0
     tx_512_1023_byte_frames: 0
     tx_1024_1518_byte_frames: 0
     tx_greater_than_1518_byte_frames: 0
     tx_underrun: 0
     tx_single_collision_frames: 0
     tx_multiple_collision_frames: 0
     tx_excessive_collisions: 0
     tx_late_collisions: 0
     tx_deferred_frames: 0
     tx_carrier_sense_errors: 0
     rx_octets: 0
     rx_frames: 0
     rx_broadcast_frames: 0
     rx_multicast_frames: 0
     rx_pause_frames: 0
     rx_64_byte_frames: 0
     rx_65_127_byte_frames: 0
     rx_128_255_byte_frames: 0
     rx_256_511_byte_frames: 0
     rx_512_1023_byte_frames: 0
     rx_1024_1518_byte_frames: 0
     rx_greater_than_1518_byte_frames: 0
     rx_undersized_frames: 0
     rx_oversize_frames: 0
     rx_jabbers: 0
     rx_frame_check_sequence_errors: 0
     rx_length_field_frame_errors: 0
     rx_symbol_errors: 0
     rx_alignment_errors: 0
     rx_resource_errors: 0
     rx_overruns: 0
     rx_ip_header_checksum_errors: 0
     rx_tcp_checksum_errors: 0
     rx_udp_checksum_errors: 0
     q0_rx_packets: 0
     q0_rx_bytes: 0
     q0_rx_dropped: 0
     q0_tx_packets: 0
     q0_tx_bytes: 0
     q0_tx_dropped: 0
     q1_rx_packets: 0
     q1_rx_bytes: 0
     q1_rx_dropped: 0
     q1_tx_packets: 0
     q1_tx_bytes: 0
     q1_tx_dropped: 0
     q2_rx_packets: 0
     q2_rx_bytes: 0
     q2_rx_dropped: 0
     q2_tx_packets: 0
     q2_tx_bytes: 0
     q2_tx_dropped: 0
     q3_rx_packets: 0
     q3_rx_bytes: 0
     q3_rx_dropped: 0
     q3_tx_packets: 0
     q3_tx_bytes: 0
     q3_tx_dropped: 0
     p04_: 0
     p04_n_runt: 0
     p04_n_soferr: 0
     p04_n_alignerr: 0
     p04_n_miierr: 0
     p04_typeerr: 0
     p04_sizeerr: 0
     p04_tctimeout: 0
     p04_priorerr: 0
     p04_nomaster: 0
     p04_memov: 0
     p04_memerr: 0
     p04_invtyp: 0
     p04_intcyov: 0
     p04_domerr: 0
     p04_pcfbagdrop: 0
     p04_spcprior: 0
     p04_ageprior: 0
     p04_portdrop: 0
     p04_lendrop: 0
     p04_bagdrop: 0
     p04_policeerr: 0
     p04_drpnona664err: 0
     p04_spcerr: 0
     p04_agedrp: 0
     p04_n_n664err: 0
     p04_n_vlanerr: 0
     p04_n_unreleased: 0
     p04_n_sizeerr: 0
     p04_n_crcerr: 0
     p04_n_vlnotfound: 0
     p04_n_ctpolerr: 0
     p04_n_polerr: 0
     p04_n_rxfrm: 0
     p04_n_rxbyte: 0
     p04_n_txfrm: 8
     p04_n_txbyte: 1722
     p04_n_qfull: 0
     p04_n_part_drop: 0
     p04_n_egr_disabled: 0
     p04_n_not_reach: 0
     p04_n_drops_nolearn: 0
     p04_n_drops_noroute: 0
     p04_n_drops_ill_dtag: 0
     p04_n_drops_dtag: 0
     p04_n_drops_sotag: 0
     p04_n_drops_sitag: 0
     p04_n_drops_utag: 0
     p04_n_tx_bytes_1024_2047: 0
     p04_n_tx_bytes_512_1023: 2
     p04_n_tx_bytes_256_511: 0
     p04_n_tx_bytes_128_255: 0
     p04_n_tx_bytes_65_127: 6
     p04_n_tx_bytes_64: 0
     p04_n_tx_mcast: 8
     p04_n_tx_bcast: 0
     p04_n_rx_bytes_1024_2047: 0
     p04_n_rx_bytes_512_1023: 0
     p04_n_rx_bytes_256_511: 0
     p04_n_rx_bytes_128_255: 0
     p04_n_rx_bytes_65_127: 0
     p04_n_rx_bytes_64: 0
     p04_n_rx_mcast: 0
# ping -I rj45 192.168.1.2
PING 192.168.1.2 (192.168.1.2): 56 data bytes
^C
--- 192.168.1.2 ping statistics ---
5 packets transmitted, 0 packets received, 100% packet loss
# ethtool -S eth0
NIC statistics:
     tx_octets: 0
     tx_frames: 0
     tx_broadcast_frames: 0
     tx_multicast_frames: 0
     tx_pause_frames: 0
     tx_64_byte_frames: 0
     tx_65_127_byte_frames: 0
     tx_128_255_byte_frames: 0
     tx_256_511_byte_frames: 0
     tx_512_1023_byte_frames: 0
     tx_1024_1518_byte_frames: 0
     tx_greater_than_1518_byte_frames: 0
     tx_underrun: 0
     tx_single_collision_frames: 0
     tx_multiple_collision_frames: 0
     tx_excessive_collisions: 0
     tx_late_collisions: 0
     tx_deferred_frames: 0
     tx_carrier_sense_errors: 0
     rx_octets: 0
     rx_frames: 0
     rx_broadcast_frames: 0
     rx_multicast_frames: 0
     rx_pause_frames: 0
     rx_64_byte_frames: 0
     rx_65_127_byte_frames: 0
     rx_128_255_byte_frames: 0
     rx_256_511_byte_frames: 0
     rx_512_1023_byte_frames: 0
     rx_1024_1518_byte_frames: 0
     rx_greater_than_1518_byte_frames: 0
     rx_undersized_frames: 0
     rx_oversize_frames: 0
     rx_jabbers: 0
     rx_frame_check_sequence_errors: 0
     rx_length_field_frame_errors: 0
     rx_symbol_errors: 0
     rx_alignment_errors: 0
     rx_resource_errors: 0
     rx_overruns: 0
     rx_ip_header_checksum_errors: 0
     rx_tcp_checksum_errors: 0
     rx_udp_checksum_errors: 0
     q0_rx_packets: 0
     q0_rx_bytes: 0
     q0_rx_dropped: 0
     q0_tx_packets: 0
     q0_tx_bytes: 0
     q0_tx_dropped: 0
     q1_rx_packets: 0
     q1_rx_bytes: 0
     q1_rx_dropped: 0
     q1_tx_packets: 0
     q1_tx_bytes: 0
     q1_tx_dropped: 0
     q2_rx_packets: 0
     q2_rx_bytes: 0
     q2_rx_dropped: 0
     q2_tx_packets: 0
     q2_tx_bytes: 0
     q2_tx_dropped: 0
     q3_rx_packets: 0
     q3_rx_bytes: 0
     q3_rx_dropped: 0
     q3_tx_packets: 0
     q3_tx_bytes: 0
     q3_tx_dropped: 0
     p04_: 0
     p04_n_runt: 0
     p04_n_soferr: 0
     p04_n_alignerr: 0
     p04_n_miierr: 0
     p04_typeerr: 0
     p04_sizeerr: 0
     p04_tctimeout: 0
     p04_priorerr: 0
     p04_nomaster: 0
     p04_memov: 0
     p04_memerr: 0
     p04_invtyp: 0
     p04_intcyov: 0
     p04_domerr: 0
     p04_pcfbagdrop: 0
     p04_spcprior: 0
     p04_ageprior: 0
     p04_portdrop: 0
     p04_lendrop: 0
     p04_bagdrop: 0
     p04_policeerr: 0
     p04_drpnona664err: 0
     p04_spcerr: 0
     p04_agedrp: 0
     p04_n_n664err: 0
     p04_n_vlanerr: 0
     p04_n_unreleased: 0
     p04_n_sizeerr: 0
     p04_n_crcerr: 0
     p04_n_vlnotfound: 0
     p04_n_ctpolerr: 0
     p04_n_polerr: 0
     p04_n_rxfrm: 0
     p04_n_rxbyte: 0
     p04_n_txfrm: 8
     p04_n_txbyte: 1722
     p04_n_qfull: 0
     p04_n_part_drop: 0
     p04_n_egr_disabled: 0
     p04_n_not_reach: 0
     p04_n_drops_nolearn: 0
     p04_n_drops_noroute: 0
     p04_n_drops_ill_dtag: 0
     p04_n_drops_dtag: 0
     p04_n_drops_sotag: 0
     p04_n_drops_sitag: 0
     p04_n_drops_utag: 0
     p04_n_tx_bytes_1024_2047: 0
     p04_n_tx_bytes_512_1023: 2
     p04_n_tx_bytes_256_511: 0
     p04_n_tx_bytes_128_255: 0
     p04_n_tx_bytes_65_127: 6
     p04_n_tx_bytes_64: 0
     p04_n_tx_mcast: 8
     p04_n_tx_bcast: 0
     p04_n_rx_bytes_1024_2047: 0
     p04_n_rx_bytes_512_1023: 0
     p04_n_rx_bytes_256_511: 0
     p04_n_rx_bytes_128_255: 0
     p04_n_rx_bytes_65_127: 0
     p04_n_rx_bytes_64: 0
     p04_n_rx_mcast: 0
# ethtool -S rj45
NIC statistics:
     tx_packets: 26
     tx_bytes: 1496
     rx_packets: 0
     rx_bytes: 0
     : 0
     n_runt: 0
     n_soferr: 0
     n_alignerr: 0
     n_miierr: 0
     typeerr: 0
     sizeerr: 0
     tctimeout: 0
     priorerr: 0
     nomaster: 0
     memov: 0
     memerr: 0
     invtyp: 0
     intcyov: 0
     domerr: 0
     pcfbagdrop: 0
     spcprior: 0
     ageprior: 0
     portdrop: 0
     lendrop: 0
     bagdrop: 0
     policeerr: 0
     drpnona664err: 0
     spcerr: 0
     agedrp: 0
     n_n664err: 0
     n_vlanerr: 0
     n_unreleased: 0
     n_sizeerr: 0
     n_crcerr: 0
     n_vlnotfound: 0
     n_ctpolerr: 0
     n_polerr: 0
     n_rxfrm: 9
     n_rxbyte: 1781
     n_txfrm: 0
     n_txbyte: 0
     n_qfull: 0
     n_part_drop: 0
     n_egr_disabled: 0
     n_not_reach: 9
     n_drops_nolearn: 0
     n_drops_noroute: 0
     n_drops_ill_dtag: 0
     n_drops_dtag: 0
     n_drops_sotag: 0
     n_drops_sitag: 0
     n_drops_utag: 0
     n_tx_bytes_1024_2047: 0
     n_tx_bytes_512_1023: 0
     n_tx_bytes_256_511: 0
     n_tx_bytes_128_255: 0
     n_tx_bytes_65_127: 0
     n_tx_bytes_64: 0
     n_tx_mcast: 0
     n_tx_bcast: 0
     n_rx_bytes_1024_2047: 0
     n_rx_bytes_512_1023: 2
     n_rx_bytes_256_511: 0
     n_rx_bytes_128_255: 0
     n_rx_bytes_65_127: 1
     n_rx_bytes_64: 6
     n_rx_mcast: 9
////////////////// PING Laptop TO Board //////////////////
# ethtool -S rj45
NIC statistics:
     tx_packets: 26
     tx_bytes: 1496
     rx_packets: 0
     rx_bytes: 0
     : 0
     n_runt: 0
     n_soferr: 0
     n_alignerr: 0
     n_miierr: 0
     typeerr: 0
     sizeerr: 0
     tctimeout: 0
     priorerr: 0
     nomaster: 0
     memov: 0
     memerr: 0
     invtyp: 0
     intcyov: 0
     domerr: 0
     pcfbagdrop: 0
     spcprior: 0
     ageprior: 0
     portdrop: 0
     lendrop: 0
     bagdrop: 0
     policeerr: 0
     drpnona664err: 0
     spcerr: 0
     agedrp: 0
     n_n664err: 0
     n_vlanerr: 0
     n_unreleased: 0
     n_sizeerr: 0
     n_crcerr: 0
     n_vlnotfound: 0
     n_ctpolerr: 0
     n_polerr: 0
     n_rxfrm: 15
     n_rxbyte: 2165
     n_txfrm: 0
     n_txbyte: 0
     n_qfull: 0
     n_part_drop: 0
     n_egr_disabled: 0
     n_not_reach: 9
     n_drops_nolearn: 0
     n_drops_noroute: 0
     n_drops_ill_dtag: 0
     n_drops_dtag: 0
     n_drops_sotag: 0
     n_drops_sitag: 0
     n_drops_utag: 0
     n_tx_bytes_1024_2047: 0
     n_tx_bytes_512_1023: 0
     n_tx_bytes_256_511: 0
     n_tx_bytes_128_255: 0
     n_tx_bytes_65_127: 0
     n_tx_bytes_64: 0
     n_tx_mcast: 0
     n_tx_bcast: 0
     n_rx_bytes_1024_2047: 0
     n_rx_bytes_512_1023: 2
     n_rx_bytes_256_511: 0
     n_rx_bytes_128_255: 0
     n_rx_bytes_65_127: 1
     n_rx_bytes_64: 12
     n_rx_mcast: 9


2.) On T1 ports, I was checking the wrong T1 ports; the link comes UP on T1 ports loopback also, but the ping doesn't work as above.

Log for the same.

========================================
SJA1110 T1 Loopback Test
Thu Jan  1 00:03:16 UTC 1970
========================================

=== Bring Interfaces Up ===

=== Configure IP Addresses ===
15: t1-5@eth0:  mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether e6:e8:ae:30:6b:84 brd ff:ff:ff:ff:ff:ff
    inet 192.168.10.1/24 scope global t1-5
       valid_lft forever preferred_lft forever
16: t1-6@eth0:  mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether e6:e8:ae:30:6b:84 brd ff:ff:ff:ff:ff:ff
    inet 192.168.10.2/24 scope global t1-6
       valid_lft forever preferred_lft forever

=== Link Status ===
Settings for t1-5:
	Supported ports: [ ]
	Supported link modes:   100baseT1/Full 
	Supported pause frame use: No
	Supports auto-negotiation: No
	Supported FEC modes: Not reported
	Advertised link modes:  100baseT1/Full 
	Advertised pause frame use: No
	Advertised auto-negotiation: No
	Advertised FEC modes: Not reported
	Speed: 100Mb/s
	Duplex: Full
	Port: MII
	PHYAD: 5
	Transceiver: external
	Auto-negotiation: off
	Supports Wake-on: d
	Wake-on: d
	Link detected: yes
Settings for t1-6:
	Supported ports: [ ]
	Supported link modes:   100baseT1/Full 
	Supported pause frame use: No
	Supports auto-negotiation: No
	Supported FEC modes: Not reported
	Advertised link modes:  100baseT1/Full 
	Advertised pause frame use: No
	Advertised auto-negotiation: No
	Advertised FEC modes: Not reported
	Speed: 100Mb/s
	Duplex: Full
	Port: MII
	PHYAD: 6
	Transceiver: external
	Auto-negotiation: off
	Supports Wake-on: d
	Wake-on: d
	Link detected: yes

=== VLAN Configuration ===
port              vlan-id  

=== FDB Before Traffic ===
33:33:00:00:00:01 dev bond0 self permanent
33:33:00:00:00:01 dev eth0 self permanent
01:00:5e:00:00:01 dev eth0 self permanent
33:33:00:00:00:01 dev eth1 self permanent

=== Interface Counters BEFORE ===
5: eth0:  mtu 1536 qdisc mq state DOWN mode DEFAULT group default qlen 1000
    link/ether e6:e8:ae:30:6b:84 brd ff:ff:ff:ff:ff:ff
    RX:  bytes packets errors dropped  missed   mcast           
             0       0      0       0       0       0 
    TX:  bytes packets errors dropped carrier collsns           
             0       0      0      16       0       0 
15: t1-5@eth0:  mtu 1500 qdisc noqueue state UP mode DEFAULT group default qlen 1000
    link/ether e6:e8:ae:30:6b:84 brd ff:ff:ff:ff:ff:ff
    RX:  bytes packets errors dropped  missed   mcast           
             0       0      0       0       0       0 
    TX:  bytes packets errors dropped carrier collsns           
           696       8      0       0       0       0 
16: t1-6@eth0:  mtu 1500 qdisc noqueue state UP mode DEFAULT group default qlen 1000
    link/ether e6:e8:ae:30:6b:84 brd ff:ff:ff:ff:ff:ff
    RX:  bytes packets errors dropped  missed   mcast           
             0       0      0       0       0       0 
    TX:  bytes packets errors dropped carrier collsns           
           696       8      0       0       0       0 

=== Ethtool Stats BEFORE ===
NIC statistics:
     tx_octets: 0
     tx_frames: 0
     tx_broadcast_frames: 0
     tx_multicast_frames: 0
     tx_pause_frames: 0
     tx_64_byte_frames: 0
     tx_65_127_byte_frames: 0
     tx_128_255_byte_frames: 0
     tx_256_511_byte_frames: 0
     tx_512_1023_byte_frames: 0
     tx_1024_1518_byte_frames: 0
     tx_greater_than_1518_byte_frames: 0
     tx_underrun: 0
     tx_single_collision_frames: 0
     tx_multiple_collision_frames: 0
     tx_excessive_collisions: 0
     tx_late_collisions: 0
     tx_deferred_frames: 0
     tx_carrier_sense_errors: 0
     rx_octets: 0
     rx_frames: 0
     rx_broadcast_frames: 0
     rx_multicast_frames: 0
     rx_pause_frames: 0
     rx_64_byte_frames: 0
     rx_65_127_byte_frames: 0
     rx_128_255_byte_frames: 0
     rx_256_511_byte_frames: 0
     rx_512_1023_byte_frames: 0
     rx_1024_1518_byte_frames: 0
     rx_greater_than_1518_byte_frames: 0
     rx_undersized_frames: 0
     rx_oversize_frames: 0
     rx_jabbers: 0
     rx_frame_check_sequence_errors: 0
     rx_length_field_frame_errors: 0
     rx_symbol_errors: 0
     rx_alignment_errors: 0
     rx_resource_errors: 0
     rx_overruns: 0
     rx_ip_header_checksum_errors: 0
     rx_tcp_checksum_errors: 0
     rx_udp_checksum_errors: 0
     q0_rx_packets: 0
     q0_rx_bytes: 0
     q0_rx_dropped: 0
     q0_tx_packets: 0
     q0_tx_bytes: 0
     q0_tx_dropped: 0
     q1_rx_packets: 0
     q1_rx_bytes: 0
     q1_rx_dropped: 0
     q1_tx_packets: 0
     q1_tx_bytes: 0
     q1_tx_dropped: 0
     q2_rx_packets: 0
     q2_rx_bytes: 0
     q2_rx_dropped: 0
     q2_tx_packets: 0
     q2_tx_bytes: 0
     q2_tx_dropped: 0
     q3_rx_packets: 0
     q3_rx_bytes: 0
     q3_rx_dropped: 0
     q3_tx_packets: 0
     q3_tx_bytes: 0
     q3_tx_dropped: 0
     p04_: 0
     p04_n_runt: 0
     p04_n_soferr: 0
     p04_n_alignerr: 0
     p04_n_miierr: 0
     p04_typeerr: 0
     p04_sizeerr: 0
     p04_tctimeout: 0
     p04_priorerr: 0
     p04_nomaster: 0
     p04_memov: 0
     p04_memerr: 0
     p04_invtyp: 0
     p04_intcyov: 0
     p04_domerr: 0
     p04_pcfbagdrop: 0
     p04_spcprior: 0
     p04_ageprior: 0
     p04_portdrop: 0
     p04_lendrop: 0
     p04_bagdrop: 0
     p04_policeerr: 0
     p04_drpnona664err: 0
     p04_spcerr: 0
     p04_agedrp: 0
     p04_n_n664err: 0
     p04_n_vlanerr: 0
     p04_n_unreleased: 0
     p04_n_sizeerr: 0
     p04_n_crcerr: 0
     p04_n_vlnotfound: 0
     p04_n_ctpolerr: 0
     p04_n_polerr: 0
     p04_n_rxfrm: 0
     p04_n_rxbyte: 0
     p04_n_txfrm: 0
     p04_n_txbyte: 0
     p04_n_qfull: 0
     p04_n_part_drop: 0
     p04_n_egr_disabled: 0
     p04_n_not_reach: 0
     p04_n_drops_nolearn: 0
     p04_n_drops_noroute: 0
     p04_n_drops_ill_dtag: 0
     p04_n_drops_dtag: 0
     p04_n_drops_sotag: 0
     p04_n_drops_sitag: 0
     p04_n_drops_utag: 0
     p04_n_tx_bytes_1024_2047: 0
     p04_n_tx_bytes_512_1023: 0
     p04_n_tx_bytes_256_511: 0
     p04_n_tx_bytes_128_255: 0
     p04_n_tx_bytes_65_127: 0
     p04_n_tx_bytes_64: 0
     p04_n_tx_mcast: 0
     p04_n_tx_bcast: 0
     p04_n_rx_bytes_1024_2047: 0
     p04_n_rx_bytes_512_1023: 0
     p04_n_rx_bytes_256_511: 0
     p04_n_rx_bytes_128_255: 0
     p04_n_rx_bytes_65_127: 0
     p04_n_rx_bytes_64: 0
     p04_n_rx_mcast: 0
NIC statistics:
     tx_packets: 8
     tx_bytes: 696
     rx_packets: 0
     rx_bytes: 0
     : 0
     n_runt: 0
     n_soferr: 0
     n_alignerr: 0
     n_miierr: 0
     typeerr: 0
     sizeerr: 0
     tctimeout: 0
     priorerr: 0
     nomaster: 0
     memov: 0
     memerr: 0
     invtyp: 0
     intcyov: 0
     domerr: 0
     pcfbagdrop: 0
     spcprior: 0
     ageprior: 0
     portdrop: 0
     lendrop: 0
     bagdrop: 0
     policeerr: 0
     drpnona664err: 0
     spcerr: 0
     agedrp: 0
     n_n664err: 0
     n_vlanerr: 0
     n_unreleased: 0
     n_sizeerr: 0
     n_crcerr: 0
     n_vlnotfound: 0
     n_ctpolerr: 0
     n_polerr: 0
     n_rxfrm: 0
     n_rxbyte: 0
     n_txfrm: 0
     n_txbyte: 0
     n_qfull: 0
     n_part_drop: 0
     n_egr_disabled: 0
     n_not_reach: 0
     n_drops_nolearn: 0
     n_drops_noroute: 0
     n_drops_ill_dtag: 0
     n_drops_dtag: 0
     n_drops_sotag: 0
     n_drops_sitag: 0
     n_drops_utag: 0
     n_tx_bytes_1024_2047: 0
     n_tx_bytes_512_1023: 0
     n_tx_bytes_256_511: 0
     n_tx_bytes_128_255: 0
     n_tx_bytes_65_127: 0
     n_tx_bytes_64: 0
     n_tx_mcast: 0
     n_tx_bcast: 0
     n_rx_bytes_1024_2047: 0
     n_rx_bytes_512_1023: 0
     n_rx_bytes_256_511: 0
     n_rx_bytes_128_255: 0
     n_rx_bytes_65_127: 0
     n_rx_bytes_64: 0
     n_rx_mcast: 0
NIC statistics:
     tx_packets: 8
     tx_bytes: 696
     rx_packets: 0
     rx_bytes: 0
     : 0
     n_runt: 0
     n_soferr: 0
     n_alignerr: 0
     n_miierr: 0
     typeerr: 0
     sizeerr: 0
     tctimeout: 0
     priorerr: 0
     nomaster: 0
     memov: 0
     memerr: 0
     invtyp: 0
     intcyov: 0
     domerr: 0
     pcfbagdrop: 0
     spcprior: 0
     ageprior: 0
     portdrop: 0
     lendrop: 0
     bagdrop: 0
     policeerr: 0
     drpnona664err: 0
     spcerr: 0
     agedrp: 0
     n_n664err: 0
     n_vlanerr: 0
     n_unreleased: 0
     n_sizeerr: 0
     n_crcerr: 0
     n_vlnotfound: 0
     n_ctpolerr: 0
     n_polerr: 0
     n_rxfrm: 0
     n_rxbyte: 0
     n_txfrm: 0
     n_txbyte: 0
     n_qfull: 0
     n_part_drop: 0
     n_egr_disabled: 0
     n_not_reach: 0
     n_drops_nolearn: 0
     n_drops_noroute: 0
     n_drops_ill_dtag: 0
     n_drops_dtag: 0
     n_drops_sotag: 0
     n_drops_sitag: 0
     n_drops_utag: 0
     n_tx_bytes_1024_2047: 0
     n_tx_bytes_512_1023: 0
     n_tx_bytes_256_511: 0
     n_tx_bytes_128_255: 0
     n_tx_bytes_65_127: 0
     n_tx_bytes_64: 0
     n_tx_mcast: 0
     n_tx_bcast: 0
     n_rx_bytes_1024_2047: 0
     n_rx_bytes_512_1023: 0
     n_rx_bytes_256_511: 0
     n_rx_bytes_128_255: 0
     n_rx_bytes_65_127: 0
     n_rx_bytes_64: 0
     n_rx_mcast: 0

=== ARP Test ===
ARPING 192.168.10.2 from 192.168.10.1 t1-5
Sent 10 probe(s) (0 broadcast(s))
Received 0 response(s) (0 request(s), 0 broadcast(s))

=== Neighbor Table ===

=== Interface Counters AFTER ===
5: eth0:  mtu 1536 qdisc mq state DOWN mode DEFAULT group default qlen 1000
    link/ether e6:e8:ae:30:6b:84 brd ff:ff:ff:ff:ff:ff
    RX:  bytes packets errors dropped  missed   mcast           
             0       0      0       0       0       0 
    TX:  bytes packets errors dropped carrier collsns           
             0       0      0      26       0       0 
15: t1-5@eth0:  mtu 1500 qdisc noqueue state UP mode DEFAULT group default qlen 1000
    link/ether e6:e8:ae:30:6b:84 brd ff:ff:ff:ff:ff:ff
    RX:  bytes packets errors dropped  missed   mcast           
             0       0      0       0       0       0 
    TX:  bytes packets errors dropped carrier collsns           
          1116      18      0       0       0       0 
16: t1-6@eth0:  mtu 1500 qdisc noqueue state UP mode DEFAULT group default qlen 1000
    link/ether e6:e8:ae:30:6b:84 brd ff:ff:ff:ff:ff:ff
    RX:  bytes packets errors dropped  missed   mcast           
             0       0      0       0       0       0 
    TX:  bytes packets errors dropped carrier collsns           
           696       8      0       0       0       0 

=== Ethtool Stats AFTER ===
NIC statistics:
     tx_octets: 0
     tx_frames: 0
     tx_broadcast_frames: 0
     tx_multicast_frames: 0
     tx_pause_frames: 0
     tx_64_byte_frames: 0
     tx_65_127_byte_frames: 0
     tx_128_255_byte_frames: 0
     tx_256_511_byte_frames: 0
     tx_512_1023_byte_frames: 0
     tx_1024_1518_byte_frames: 0
     tx_greater_than_1518_byte_frames: 0
     tx_underrun: 0
     tx_single_collision_frames: 0
     tx_multiple_collision_frames: 0
     tx_excessive_collisions: 0
     tx_late_collisions: 0
     tx_deferred_frames: 0
     tx_carrier_sense_errors: 0
     rx_octets: 0
     rx_frames: 0
     rx_broadcast_frames: 0
     rx_multicast_frames: 0
     rx_pause_frames: 0
     rx_64_byte_frames: 0
     rx_65_127_byte_frames: 0
     rx_128_255_byte_frames: 0
     rx_256_511_byte_frames: 0
     rx_512_1023_byte_frames: 0
     rx_1024_1518_byte_frames: 0
     rx_greater_than_1518_byte_frames: 0
     rx_undersized_frames: 0
     rx_oversize_frames: 0
     rx_jabbers: 0
     rx_frame_check_sequence_errors: 0
     rx_length_field_frame_errors: 0
     rx_symbol_errors: 0
     rx_alignment_errors: 0
     rx_resource_errors: 0
     rx_overruns: 0
     rx_ip_header_checksum_errors: 0
     rx_tcp_checksum_errors: 0
     rx_udp_checksum_errors: 0
     q0_rx_packets: 0
     q0_rx_bytes: 0
     q0_rx_dropped: 0
     q0_tx_packets: 0
     q0_tx_bytes: 0
     q0_tx_dropped: 0
     q1_rx_packets: 0
     q1_rx_bytes: 0
     q1_rx_dropped: 0
     q1_tx_packets: 0
     q1_tx_bytes: 0
     q1_tx_dropped: 0
     q2_rx_packets: 0
     q2_rx_bytes: 0
     q2_rx_dropped: 0
     q2_tx_packets: 0
     q2_tx_bytes: 0
     q2_tx_dropped: 0
     q3_rx_packets: 0
     q3_rx_bytes: 0
     q3_rx_dropped: 0
     q3_tx_packets: 0
     q3_tx_bytes: 0
     q3_tx_dropped: 0
     p04_: 0
     p04_n_runt: 0
     p04_n_soferr: 0
     p04_n_alignerr: 0
     p04_n_miierr: 0
     p04_typeerr: 0
     p04_sizeerr: 0
     p04_tctimeout: 0
     p04_priorerr: 0
     p04_nomaster: 0
     p04_memov: 0
     p04_memerr: 0
     p04_invtyp: 0
     p04_intcyov: 0
     p04_domerr: 0
     p04_pcfbagdrop: 0
     p04_spcprior: 0
     p04_ageprior: 0
     p04_portdrop: 0
     p04_lendrop: 0
     p04_bagdrop: 0
     p04_policeerr: 0
     p04_drpnona664err: 0
     p04_spcerr: 0
     p04_agedrp: 0
     p04_n_n664err: 0
     p04_n_vlanerr: 0
     p04_n_unreleased: 0
     p04_n_sizeerr: 0
     p04_n_crcerr: 0
     p04_n_vlnotfound: 0
     p04_n_ctpolerr: 0
     p04_n_polerr: 0
     p04_n_rxfrm: 0
     p04_n_rxbyte: 0
     p04_n_txfrm: 0
     p04_n_txbyte: 0
     p04_n_qfull: 0
     p04_n_part_drop: 0
     p04_n_egr_disabled: 0
     p04_n_not_reach: 0
     p04_n_drops_nolearn: 0
     p04_n_drops_noroute: 0
     p04_n_drops_ill_dtag: 0
     p04_n_drops_dtag: 0
     p04_n_drops_sotag: 0
     p04_n_drops_sitag: 0
     p04_n_drops_utag: 0
     p04_n_tx_bytes_1024_2047: 0
     p04_n_tx_bytes_512_1023: 0
     p04_n_tx_bytes_256_511: 0
     p04_n_tx_bytes_128_255: 0
     p04_n_tx_bytes_65_127: 0
     p04_n_tx_bytes_64: 0
     p04_n_tx_mcast: 0
     p04_n_tx_bcast: 0
     p04_n_rx_bytes_1024_2047: 0
     p04_n_rx_bytes_512_1023: 0
     p04_n_rx_bytes_256_511: 0
     p04_n_rx_bytes_128_255: 0
     p04_n_rx_bytes_65_127: 0
     p04_n_rx_bytes_64: 0
     p04_n_rx_mcast: 0
NIC statistics:
     tx_packets: 18
     tx_bytes: 1116
     rx_packets: 0
     rx_bytes: 0
     : 0
     n_runt: 0
     n_soferr: 0
     n_alignerr: 0
     n_miierr: 0
     typeerr: 0
     sizeerr: 0
     tctimeout: 0
     priorerr: 0
     nomaster: 0
     memov: 0
     memerr: 0
     invtyp: 0
     intcyov: 0
     domerr: 0
     pcfbagdrop: 0
     spcprior: 0
     ageprior: 0
     portdrop: 0
     lendrop: 0
     bagdrop: 0
     policeerr: 0
     drpnona664err: 0
     spcerr: 0
     agedrp: 0
     n_n664err: 0
     n_vlanerr: 0
     n_unreleased: 0
     n_sizeerr: 0
     n_crcerr: 0
     n_vlnotfound: 0
     n_ctpolerr: 0
     n_polerr: 0
     n_rxfrm: 0
     n_rxbyte: 0
     n_txfrm: 0
     n_txbyte: 0
     n_qfull: 0
     n_part_drop: 0
     n_egr_disabled: 0
     n_not_reach: 0
     n_drops_nolearn: 0
     n_drops_noroute: 0
     n_drops_ill_dtag: 0
     n_drops_dtag: 0
     n_drops_sotag: 0
     n_drops_sitag: 0
     n_drops_utag: 0
     n_tx_bytes_1024_2047: 0
     n_tx_bytes_512_1023: 0
     n_tx_bytes_256_511: 0
     n_tx_bytes_128_255: 0
     n_tx_bytes_65_127: 0
     n_tx_bytes_64: 0
     n_tx_mcast: 0
     n_tx_bcast: 0
     n_rx_bytes_1024_2047: 0
     n_rx_bytes_512_1023: 0
     n_rx_bytes_256_511: 0
     n_rx_bytes_128_255: 0
     n_rx_bytes_65_127: 0
     n_rx_bytes_64: 0
     n_rx_mcast: 0
NIC statistics:
     tx_packets: 8
     tx_bytes: 696
     rx_packets: 0
     rx_bytes: 0
     : 0
     n_runt: 0
     n_soferr: 0
     n_alignerr: 0
     n_miierr: 0
     typeerr: 0
     sizeerr: 0
     tctimeout: 0
     priorerr: 0
     nomaster: 0
     memov: 0
     memerr: 0
     invtyp: 0
     intcyov: 0
     domerr: 0
     pcfbagdrop: 0
     spcprior: 0
     ageprior: 0
     portdrop: 0
     lendrop: 0
     bagdrop: 0
     policeerr: 0
     drpnona664err: 0
     spcerr: 0
     agedrp: 0
     n_n664err: 0
     n_vlanerr: 0
     n_unreleased: 0
     n_sizeerr: 0
     n_crcerr: 0
     n_vlnotfound: 0
     n_ctpolerr: 0
     n_polerr: 0
     n_rxfrm: 0
     n_rxbyte: 0
     n_txfrm: 0
     n_txbyte: 0
     n_qfull: 0
     n_part_drop: 0
     n_egr_disabled: 0
     n_not_reach: 0
     n_drops_nolearn: 0
     n_drops_noroute: 0
     n_drops_ill_dtag: 0
     n_drops_dtag: 0
     n_drops_sotag: 0
     n_drops_sitag: 0
     n_drops_utag: 0
     n_tx_bytes_1024_2047: 0
     n_tx_bytes_512_1023: 0
     n_tx_bytes_256_511: 0
     n_tx_bytes_128_255: 0
     n_tx_bytes_65_127: 0
     n_tx_bytes_64: 0
     n_tx_mcast: 0
     n_tx_bcast: 0
     n_rx_bytes_1024_2047: 0
     n_rx_bytes_512_1023: 0
     n_rx_bytes_256_511: 0
     n_rx_bytes_128_255: 0
     n_rx_bytes_65_127: 0
     n_rx_bytes_64: 0
     n_rx_mcast: 0

=== FDB After Traffic ===
33:33:00:00:00:01 dev bond0 self permanent
33:33:00:00:00:01 dev eth0 self permanent
01:00:5e:00:00:01 dev eth0 self permanent
33:33:00:00:00:01 dev eth1 self permanent

=== Dmesg Link Events ===
[    3.602806] sja1105 spi9.0: Link is Up - 1Gbps/Full - flow control off
[    3.678860] sja1105 spi9.0 t1-5 (uninitialized): PHY [spi9.0-base-t1:05] driver [Generic Clause 45 PHY] (irq=POLL)
[    3.682052] sja1105 spi9.0 t1-6 (uninitialized): PHY [spi9.0-base-t1:06] driver [Generic Clause 45 PHY] (irq=POLL)
[  196.222060] sja1105 spi9.0 t1-5: configuring for phy/internal link mode
[  196.224821] sja1105 spi9.0 t1-5: Link is Up - 100Mbps/Full - flow control off
[  196.229425] sja1105 spi9.0 t1-6: configuring for phy/internal link mode
[  196.231212] sja1105 spi9.0 t1-6: Link is Up - 100Mbps/Full - flow control off




Re: SJA1110A DSA bring UP : 100BASE-TX TX failure and T1 link training issues

Hello @Ankur_pixl ,

Thank you for the detailed logs. Feel free to correct my interpretation.

Your latest results are very useful, because they show that this is most likely no longer a bridge-only problem.

For the RJ45 direct L3 test (IP assigned directly to rj45, no bridge), the Linux netdev TX counters increase, but the hardware switch egress counters for the RJ45 port remain at 0 (`n_txfrm = 0`, `n_txbyte = 0`). At the same time, ingress counters on RJ45 do increase, which indicates that the front PHY/link is receiving frames correctly.

The T1 loopback result points in the same direction: both T1 ports reach link-up successfully, so the PHY training itself appears to work, but traffic still does not pass.

The common point in both cases is the CPU/master path:
- `eth0` remains `NO-CARRIER`
- `eth0` stays in `state DOWN`
- MACB TX/RX hardware counters remain 0
- TX dropped packets increase on `eth0`

Based on this, the main issue now appears to be the CPU conduit path between the SoC MAC (`eth0`) and the SJA1110 CPU port (p04), rather than the front RJ45 or T1 PHY ports themselves.

In other words, the switch-side ports can come up, but the host-facing SGMII/CPU-port data path does not appear to be operational.

At this stage, I would recommend focusing on the SoC MAC / PCS / SGMII configuration for `eth0` and the corresponding CPU port configuration, rather than further bridge experiments.

Please share:
1. ethtool eth0
2. ip -d link show eth0
3. the full Device Tree fragment for the SoC MAC / PCS / SGMII side connected to the switch CPU port
4. any available PCS/SGMII link status information on the SoC side

The fact that `eth0` never reaches RUNNING / carrier-up is a strong indicator and is very likely related to the traffic failure.


I reviewed your DT fragment once again, the DSA/SJA1110 part of the Device Tree looks logically consistent:
- MAC0 is configured as `sgmii` with a fixed 1 Gbps full-duplex link
- the SJA1110 CPU port is also configured as `sgmii` with a fixed 1 Gbps full-duplex link
- the internal PHY port mapping also looks correct

So I do not currently see an obvious DSA DT mistake in this fragment itself.

However, this DT fragment alone does not prove that the SoC-side SGMII/PCS/SerDes path is actually operational. Based on your counters, the switch CPU port appears active on the switch side, but `eth0` still remains `NO-CARRIER` / state DOWN, with no real MAC RX/TX traffic.

That points more to a problem in the SoC-facing SGMII/PCS/SerDes path (or its low-level initialization) rather than in the front RJ45 or T1 ports.

Could you please also share the full MAC0 / PCS / SerDes related configuration, and any bootloader / low-level configuration that initializes the SGMII lane?


Best regards,

Pavel

Re: SJA1110A DSA bring UP : 100BASE-TX TX failure and T1 link training issues

Hello @PavelL 

Yes, after carefully reviewing the schematics, I found that the SGMII TX P/N lines from the SoC to the switch were swapped. Additionally, the same SGMII lines were connected to another endpoint, which prevented the Ethernet link from coming up.

We are currently fixing these issues and will get back to you with the updated results.

-- Ankur 

タグ(1)
評価なし
バージョン履歴
最終更新日:
1週間前
更新者: