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.

AM5718: Single Ethernet port

Part Number: AM5718

SDK : ti-processor-sdk-linux-rt-am57xx-evm-05.03.00.07

u-boot : u-boot-2018.01+gitAUTOINC+313dcd69c2-ge2bc936055

kernel : linux-rt-4.14.79+gitAUTOINC+a72bf1418c-ga72bf1418c

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

I have a problem with rgmii now.

After using eth0, if you use the ethernet cable used for eth0 to eth1, it will not work. However, if you type and use "ifconfig eth0 down", it is enabled.

Do you know the cause?

I am using am5718 custom board.

  • Please complete this checklist and post the results here: processors.wiki.ti.com/.../5x_CPSW

  • Hi, Biser Gatchev-XID

    I checked, but I can't figure out the cause.

    I've tested and eth1 doesn't work unless I use eth0 first.

    The text document below shared my terminal content as a result of my testing.

    test~#  
    test~# 
    test~# 
    test~# ifconfig
    can0      Link encap:UNSPEC  HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00  
              UP RUNNING NOARP  MTU:16  Metric:1
              RX packets:18 errors:0 dropped:0 overruns:0 frame:0
              TX packets:11 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:10 
              RX bytes:48 (48.0 B)  TX bytes:68 (68.0 B)
              Interrupt:92 
    
    eth0      Link encap:Ethernet  HWaddr 24:7D:4D:FB:CF:40  
              inet addr:118.219.85.127  Bcast:118.255.255.255  Mask:255.0.0.0
              UP BROADCAST MULTICAST  MTU:1500  Metric:1
              RX packets:0 errors:0 dropped:0 overruns:0 frame:0
              TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1000 
              RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
              Interrupt:89 
    
    eth1      Link encap:Ethernet  HWaddr 24:7D:4D:FB:CF:41  
              inet addr:118.219.85.126  Bcast:118.255.255.255  Mask:255.0.0.0
              inet6 addr: fe80::267d:4dff:fefb:cf41%775872/64 Scope:Link
              UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
              RX packets:6968 errors:0 dropped:213 overruns:0 frame:0
              TX packets:35 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1000 
              RX bytes:484200 (472.8 KiB)  TX bytes:5715 (5.5 KiB)
    
    eth2      Link encap:Ethernet  HWaddr 82:B6:4F:43:B4:CE  
              UP BROADCAST MULTICAST  MTU:1500  Metric:1
              RX packets:0 errors:0 dropped:0 overruns:0 frame:0
              TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1000 
              RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
    
    eth3      Link encap:Ethernet  HWaddr A6:BD:C2:5A:5E:22  
              UP BROADCAST MULTICAST  MTU:1500  Metric:1
              RX packets:0 errors:0 dropped:0 overruns:0 frame:0
              TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1000 
              RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
    
    lo        Link encap:Local Loopback  
              inet addr:127.0.0.1  Mask:255.0.0.0
              inet6 addr: ::1%775872/128 Scope:Host
              UP LOOPBACK RUNNING  MTU:65536  Metric:1
              RX packets:284 errors:0 dropped:0 overruns:0 frame:0
              TX packets:284 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1000 
              RX bytes:25803 (25.1 KiB)  TX bytes:25803 (25.1 KiB)
    
    test~# ethtool eth1
    Settings for eth1:
            Supported ports: [ TP MII ]
            Supported link modes:   10baseT/Half 10baseT/Full 
                                    100baseT/Half 100baseT/Full 
                                    1000baseT/Half 1000baseT/Full 
            Supported pause frame use: Symmetric Receive-only
            Supports auto-negotiation: Yes
            Supported FEC modes: Not reported
            Advertised link modes:  10baseT/Full 
            Advertised pause frame use: No
            Advertised auto-negotiation: No
            Advertised FEC modes: Not reported
            Speed: 10Mb/s
            Duplex: Full
            Port: MII
            PHYAD: 0
            Transceiver: internal
            Auto-negotiation: off
            Supports Wake-on: d
            Wake-on: d
            Current message level: 0x00000000 (0)
                                   
            Link detected: yes
    test~# ethtool eth0
    Settings for eth0:
            Supported ports: [ TP MII ]
            Supported link modes:   10baseT/Half 10baseT/Full 
                                    100baseT/Half 100baseT/Full 
                                    1000baseT/Half 1000baseT/Full 
            Supported pause frame use: Symmetric Receive-only
            Supports auto-negotiation: Yes
            Supported FEC modes: Not reported
            Advertised link modes:  100baseT/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: internal
            Auto-negotiation: off
            Supports Wake-on: d
            Wake-on: d
            Current message level: 0x00000000 (0)
                                   
            Link detected: no
    test~# ethtool -S eth1                                                                                                                                                                                             
    NIC statistics:
         Good Rx Frames: 12418
         Broadcast Rx Frames: 7021
         Multicast Rx Frames: 5394
         Pause Rx Frames: 0
         Rx CRC Errors: 0
         Rx Align/Code Errors: 0
         Oversize Rx Frames: 0
         Rx Jabbers: 0
         Undersize (Short) Rx Frames: 0
         Rx Fragments: 0
         Rx Octets: 1150141
         Good Tx Frames: 35
         Broadcast Tx Frames: 0
         Multicast Tx Frames: 33
         Pause Tx Frames: 0
         Deferred Tx Frames: 0
         Collisions: 0
         Single Collision Tx Frames: 0
         Multiple Collision Tx Frames: 0
         Excessive Collisions: 0
         Late Collisions: 0
         Tx Underrun: 0
         Carrier Sense Errors: 0
         Tx Octets: 5855
         Rx + Tx 64 Octet Frames: 9797
         Rx + Tx 65-127 Octet Frames: 954
         Rx + Tx 128-255 Octet Frames: 682
         Rx + Tx 256-511 Octet Frames: 1016
         Rx + Tx 512-1023 Octet Frames: 4
         Rx + Tx 1024-Up Octet Frames: 0
         Net Octets: 1155996
         Rx Start of Frame Overruns: 0
         Rx Middle of Frame Overruns: 0
         Rx DMA Overruns: 0
         Rx DMA chan 0: head_enqueue: 1
         Rx DMA chan 0: tail_enqueue: 7791
         Rx DMA chan 0: pad_enqueue: 0
         Rx DMA chan 0: misqueued: 0
         Rx DMA chan 0: desc_alloc_fail: 0
         Rx DMA chan 0: pad_alloc_fail: 0
         Rx DMA chan 0: runt_receive_buf: 0
         Rx DMA chan 0: runt_transmit_bu: 0
         Rx DMA chan 0: empty_dequeue: 0
         Rx DMA chan 0: busy_dequeue: 7647
         Rx DMA chan 0: good_dequeue: 7664
         Rx DMA chan 0: requeue: 0
         Rx DMA chan 0: teardown_dequeue: 0
         Tx DMA chan 0: head_enqueue: 35
         Tx DMA chan 0: tail_enqueue: 0
         Tx DMA chan 0: pad_enqueue: 0
         Tx DMA chan 0: misqueued: 0
         Tx DMA chan 0: desc_alloc_fail: 0
         Tx DMA chan 0: pad_alloc_fail: 0
         Tx DMA chan 0: runt_receive_buf: 0
         Tx DMA chan 0: runt_transmit_bu: 2
         Tx DMA chan 0: empty_dequeue: 35
         Tx DMA chan 0: busy_dequeue: 0
         Tx DMA chan 0: good_dequeue: 35
         Tx DMA chan 0: requeue: 0
         Tx DMA chan 0: teardown_dequeue: 0
    test~# ethtool -T eth1                                                                                                                                                                                             
    Time stamping parameters for eth1:
    Capabilities:
            hardware-transmit     (SOF_TIMESTAMPING_TX_HARDWARE)
            software-transmit     (SOF_TIMESTAMPING_TX_SOFTWARE)
            hardware-receive      (SOF_TIMESTAMPING_RX_HARDWARE)
            software-receive      (SOF_TIMESTAMPING_RX_SOFTWARE)
            software-system-clock (SOF_TIMESTAMPING_SOFTWARE)
            hardware-raw-clock    (SOF_TIMESTAMPING_RAW_HARDWARE)
    PTP Hardware Clock: 0
    Hardware Transmit Timestamp Modes:
            off                   (HWTSTAMP_TX_OFF)
            on                    (HWTSTAMP_TX_ON)
    Hardware Receive Filter Modes:
            none                  (HWTSTAMP_FILTER_NONE)
            ptpv1-l4-event        (HWTSTAMP_FILTER_PTP_V1_L4_EVENT)
            ptpv2-event           (HWTSTAMP_FILTER_PTP_V2_EVENT)
    test~# ping 118.219.85.240
    PING 118.219.85.240 (118.219.85.240): 56 data bytes
    ^C
    --- 118.219.85.240 ping statistics ---
    8 packets transmitted, 0 packets received, 100% packet loss
    test~# cpsw 48484000.ethernet eth1: Link is Down
    
    test~# cpsw 48484000.ethernet eth0: Link is Up - 100Mbps/Full - flow control off
    IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
    
    test~# ping 118.219.85.240
    PING 118.219.85.240 (118.219.85.240): 56 data bytes
    64 bytes from 118.219.85.240: seq=0 ttl=64 time=0.300 ms
    64 bytes from 118.219.85.240: seq=1 ttl=64 time=0.278 ms
    64 bytes from 118.219.85.240: seq=2 ttl=64 time=0.265 ms
    64 bytes from 118.219.85.240: seq=3 ttl=64 time=0.358 ms
    ^C
    --- 118.219.85.240 ping statistics ---
    4 packets transmitted, 4 packets received, 0% packet loss
    round-trip min/avg/max = 0.265/0.300/0.358 ms
    test~# ethtool eth1
    Settings for eth1:
            Supported ports: [ TP MII ]
            Supported link modes:   10baseT/Half 10baseT/Full 
                                    100baseT/Half 100baseT/Full 
                                    1000baseT/Half 1000baseT/Full 
            Supported pause frame use: Symmetric Receive-only
            Supports auto-negotiation: Yes
            Supported FEC modes: Not reported
            Advertised link modes:  10baseT/Full 
            Advertised pause frame use: No
            Advertised auto-negotiation: No
            Advertised FEC modes: Not reported
            Speed: 10Mb/s
            Duplex: Full
            Port: MII
            PHYAD: 0
            Transceiver: internal
            Auto-negotiation: off
            Supports Wake-on: d
            Wake-on: d
            Current message level: 0x00000000 (0)
                                   
            Link detected: no
    test~# ethtool eth0
    Settings for eth0:
            Supported ports: [ TP MII ]
            Supported link modes:   10baseT/Half 10baseT/Full 
                                    100baseT/Half 100baseT/Full 
                                    1000baseT/Half 1000baseT/Full 
            Supported pause frame use: Symmetric Receive-only
            Supports auto-negotiation: Yes
            Supported FEC modes: Not reported
            Advertised link modes:  100baseT/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: internal
            Auto-negotiation: off
            Supports Wake-on: d
            Wake-on: d
            Current message level: 0x00000000 (0)
                                   
            Link detected: yes
    test~#                    
    test~# 
    test~# cpsw 48484000.ethernet eth0: Link is Down
    cpsw 48484000.ethernet eth1: Link is Up - 10Mbps/Full - flow control off
    
    test~# 
    test~# ping 118.219.85.240
    PING 118.219.85.240 (118.219.85.240): 56 data bytes
    64 bytes from 118.219.85.240: seq=0 ttl=64 time=0.737 ms
    64 bytes from 118.219.85.240: seq=1 ttl=64 time=0.490 ms
    64 bytes from 118.219.85.240: seq=2 ttl=64 time=0.397 ms
    64 bytes from 118.219.85.240: seq=3 ttl=64 time=0.435 ms
    ^C
    --- 118.219.85.240 ping statistics ---
    4 packets transmitted, 4 packets received, 0% packet loss
    round-trip min/avg/max = 0.397/0.514/0.737 ms
    test~# 
    
    

  • Hi,

    I would possibly conclude that the ports themselves are working since eth1 works after you take down eth0. One possible suggestion to why this occurring is that both ports are on the same .85 subnet:

    eth0 inet addr:118.219.85.127 Bcast:118.255.255.255 Mask:255.0.0.0

    eth1 inet addr:118.219.85.126 Bcast:118.255.255.255 Mask:255.0.0.0

    You can probably see this if you hook up a wireshark on port 0 while trying to use port 1. I have assumed that both ports are getting their ip address statically. I recommend that both ports have to be on separate networks to function correctly. What I mean be this is that they cannot be connected to the same switch. One possible topology would be to use 2 off the shelf wlan routers that can assign ip addresses, they will need to be configured to not use the same subnet. E.g. one router would provide an address of range of 192.168.10.x and the other would provide an address range of 192.168.20.x.

    Also please take a look at this training pdf starting at about slide 51 discussing the same subnet issue.

    Best Regards,

    Schuyler