This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/AM5718: PRU MII RXLINK issue

Part Number: AM5718

Tool/software: Linux

We are using AM5718 PRU Ethernet and we use DP83822I Ethernet driver. we haven't connected RXLINK. So could you guide us to enable the MDIO internal state machine.

PSDK Version : 05.03.00.07


Regards,
Suresh

  • Hello Suresh,

    I am treating this as a continuation of our discussion on your post PRU Ethernet does not work. We will cover RXLINK related information on this thread, and other issues with debugging your ethernet on the other thread. Let me know if I am making the wrong assumption about how you wanted to split the topics.

    In your previous post, you said "For your information, We have removed the rxlink input connections in AM5718-IDK then the behavior is same as our custom platform behavior. So that we requested you explain the rxlink functionality."

    Please give me more information about "the behavior is the same as our custom platform behavior". Are you saying that standard PRU Ethernet on an AM5718 IDK board will stop working if you remove the rxlink input connection? (and make no other hardware modifications) Or are you saying something else?

    Regards,

    Nick

  • Hi Nick,

    Yes, your split-up is good. We will discuss about the rxlink related things here.


    Yes,The rxlink input was disconnected by removing the "R188" from the AM5718-IDK Rev 1.3B then the PRU Ethernet doesn't work. The link-up & link-down messages are not showed while connect & remove the Ethernet cable.

    Regards,
    Suresh

  • Hello Suresh,

    It sounds like that behavior is unexpected from a PRU Ethernet Linux driver standpoint - Linux does not get the PHY link status from RXLINK. It could take a couple of days before I have more information on how we expect the PRU firmware to interact with RXLINK (if at all).

    Regards,

    Nick

  • Hello Suresh,

    Update, still waiting on firmware information. I hope to get a response this week, but team members are on vacation to celebrate 4th of July so I might not have any new information until next week.

    Regards,

    Nick

  • Hello Suresh,

    Double checking on your setup to observe your issue on the AM571x IDK board. Is this true? If not, please correct anything:

    1) the ONLY hardware modification was the removal of R188 - no other hardware was changed

    2) You used the default, out-of-the-box SD card with no software changes

    Regards,

    Nick

  • Hello Suresh,

    I am assuming you resolved your issue. If not, feel free to reply to continue the conversation.

    Regards,

    Nick

  • Hello Suresh,

    Double checking on your setup to observe your issue on the AM571x IDK board. Is this true? If not, please correct anything:

    1) the ONLY hardware modification was the removal of R188 - no other hardware was changed

    2) You used the default, out-of-the-box SD card with no software changes

    Regards,

    Nick

  • Suresh,

    The rxlink signal is optional.  For example, take a look at the ICSS1 connection of the AM572x IDK.  It doesn't use the rxlink signal at all.

    I am not 100% sure what the mechanism is to disable the rxlink.  It might be as simple as not configuring its mux.  For example, I wonder if you made this change on the AM571x IDK with the resistor removed if it would start working again:

    diff --git a/board/ti/am57xx/mux_data.h b/board/ti/am57xx/mux_data.h
    index a48f681840..c38d1545b0 100644
    --- a/board/ti/am57xx/mux_data.h
    +++ b/board/ti/am57xx/mux_data.h
    @@ -934,7 +934,6 @@ const struct pad_conf_entry core_padconf_array_icss1eth_am571x_idk[] = {
    {VOUT1_D18, (M12 | PIN_INPUT_PULLDOWN)}, /* vout1_d18.pr1_mii0_rxd1 */
    {VOUT1_D19, (M12 | PIN_INPUT_PULLDOWN)}, /* vout1_d19.pr1_mii0_rxd0 */
    {VOUT1_D20, (M12 | PIN_INPUT_PULLUP)}, /* vout1_d20.pr1_mii0_rxer */
    - {VOUT1_D21, (M12 | PIN_INPUT_PULLDOWN)}, /* vout1_d21.pr1_mii0_rxlink */
    {VOUT1_D22, (M12 | PIN_INPUT_PULLDOWN)}, /* vout1_d22.pr1_mii0_col */
    {VOUT1_D23, (M12 | PIN_INPUT_PULLDOWN)}, /* vout1_d23.pr1_mii0_crs */

    Can you check on your board if interrupts are functioning correctly.  Here's an example from my AM572x IDK:

    root@am57xx-evm:~# [ 2903.705981] prueth pruss2_eth eth3: Link is Up - 100Mbps/Full - flow control rx/tx

    cat /proc/interrupts

               CPU0       CPU1

    85:        120          0      CBAR 335 Level     48484000.ethernet

    86:         80          0      CBAR 336 Level     48484000.ethernet

    206:         14          0  48057000.gpio  30 Edge      4b2b2400.mdio:00

    207:          3          0  48057000.gpio  31 Edge      4b2b2400.mdio:01

    208:       5773          0  4b2a0000.intc  20 Edge      eth2

    209:        270          0  4b2a0000.intc  22 Edge      eth2

    210:          0          0  4b2a0000.intc  26 Edge      eth2

    211:         56          0  4b2a0000.intc  23 Edge      eth3

    212:         17          0  4b2a0000.intc  21 Edge      eth3

    213:          0          0  4b2a0000.intc  27 Edge      eth3

    In particular, I could see the interrupt count under CPU0 increment by 1 every time I unplugged or plugged in the cable.

    Best regards,
    Brad

  • Hello Suresh,

    I'm assuming you resolved the issue. If not, feel free to take a look at my and Brad's responses above and continue the conversation.

    Regards,

    Nick

  • Hi Nick,

    Sorry for the delayed response. I'm out for some other works.

    Still we are facing the issue.So we will check the Mr. suggestions and then i'll let you know.

    Thanks & Regards,
    Suresh 



  • Hi Mr.Brad griffis & Mr.Nick,

    In our custom board, the PRU Ethernet Interrupt pin not connected to AM5718 processor. After connect the PRU Ethernet interrupt pin to Processor then we able to see the Link-Up & Link-Down debug messages while connect & disconnect the Ethernet cable.

    But now we are facing the internet not connected/IP not assigned issue. Could you check below ifconfig debug print.


    Debug Print:

    root@am57xx-evm:~# [ 1073.367287] prueth pruss2_eth eth0: Link is Up - 10Mbps/Half - flow control off
    [ 1073.514166] prueth pruss2_eth eth0: Link is Down
    [ 1075.449652] prueth pruss2_eth eth0: Link is Up - 100Mbps/Full - flow control rx/tx

    root@am57xx-evm:~# ifconfig
    eth0 Link encap:Ethernet HWaddr AE:E9:D9:3B:9E:19 
    inet6 addr: fe80::ace9:d9ff:fe3b:9e19%775872/64 Scope:Link
    UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
    RX packets:0 errors:0 dropped:0 overruns:0 frame:0
    TX packets:18 errors:0 dropped:0 overruns:0 carrier:0
    collisions:0 txqueuelen:1000 
    RX bytes:0 (0.0 B) TX bytes:2760 (2.6 KiB)

    eth1 Link encap:Ethernet HWaddr 8A:7F:33:55:A3:A2 
    inet6 addr: fe80::887f:33ff:fe55:a3a2%775872/64 Scope:Link
    UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
    RX packets:0 errors:0 dropped:0 overruns:0 frame:0
    TX packets:17 errors:0 dropped:0 overruns:0 carrier:0
    collisions:0 txqueuelen:1000 
    RX bytes:0 (0.0 B) TX bytes:2690 (2.6 KiB)

    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:177 errors:0 dropped:0 overruns:0 frame:0
    TX packets:177 errors:0 dropped:0 overruns:0 carrier:0
    collisions:0 txqueuelen:1000 
    RX bytes:13860 (13.5 KiB) TX bytes:13860 (13.5 KiB)

    root@am57xx-evm:~#


    Kindly check & feedback us to resolve this issue.

    Thanks & Regards,
    Suresh

  • Please run "ethtool eth0" and "ethtool -S eth0" and provide the output.

  • Brad, thank you for jumping in.

    Brad & Suresh, I will be out for the rest of this week. I will be back next week.

    Regards,

    Nick

  • Hi Brad,

    As per your request, Here i have attached the "ethtool eth0 & ethtool -S eth0" commands entered log file for your reference. 

    Log File:AM5718_ethtool_cmd_Log.zip

     

    Regards,
    Suresh

  • HI Brad & Nick,

    Any feedback for the "ethtool eth0" and "ethtool -S eth0" command output.

    Regards,
    Suresh

  • Please download this bash script to your AM57xx board and execute it:

    http://git.ti.com/sitara-dss-files/am57xx-dss-files/blobs/raw/master/padconf/am57xx-padconf-rd1.sh

    The output will be a *.rd1 file.  Please attach it to the forum.  You can rename as *.txt if it won't attach with that extension.

  • Hi Brad, 

    Please find the uploaded "am57xx-padconf_2019-08-20_052651.txt" file for your reference. Could you check & feedback.

    File: 

    am57xx-padconf_2019-08-20_052651.txt
    PadConf AM571x
    0x4A003400 0x0005000F
    0x4A003404 0x0005000F
    0x4A003408 0x0005000F
    0x4A00340C 0x0005000F
    0x4A003410 0x0005000F
    0x4A003414 0x0005000F
    0x4A003418 0x0005000F
    0x4A00341C 0x0005000F
    0x4A003420 0x0005000F
    0x4A003424 0x0005000F
    0x4A003428 0x0005000F
    0x4A00342C 0x0005000F
    0x4A003430 0x0005000F
    0x4A003434 0x0005000F
    0x4A003438 0x0005000F
    0x4A00343C 0x0005000F
    0x4A003440 0x00050106
    0x4A003444 0x00050106
    0x4A003448 0x00050106
    0x4A00344C 0x00050106
    0x4A003450 0x00050106
    0x4A003454 0x00050106
    0x4A003458 0x00050106
    0x4A00345C 0x00050106
    0x4A003460 0x00050106
    0x4A003464 0x00050106
    0x4A003468 0x00050106
    0x4A00346C 0x0006000E
    0x4A003470 0x0006000E
    0x4A003474 0x00050101
    0x4A003478 0x00050101
    0x4A00347C 0x00050101
    0x4A003480 0x00050101
    0x4A003484 0x00050101
    0x4A003488 0x00010101
    0x4A00348C 0x00060101
    0x4A003490 0x00060101
    0x4A003494 0x00060101
    0x4A003498 0x00060101
    0x4A00349C 0x00060101
    0x4A0034A0 0x00060101
    0x4A0034A4 0x00060101
    0x4A0034A8 0x00060101
    0x4A0034AC 0x00060101
    0x4A0034B0 0x00060101
    0x4A0034B4 0x0001000E
    0x4A0034B8 0x00010101
    0x4A0034BC 0x0001000E
    0x4A0034C0 0x0005000E
    0x4A0034C4 0x0001000E
    0x4A0034C8 0x0001000E
    0x4A0034CC 0x0001000E
    0x4A0034D0 0x0001000E
    0x4A0034D4 0x0001000E
    0x4A0034D8 0x0009000E
    0x4A003554 0x0006000E
    0x4A003558 0x0006000E
    0x4A00355C 0x0006000E
    0x4A003560 0x0006000E
    0x4A003564 0x0001000E
    0x4A003568 0x0005000B
    0x4A00356C 0x0001000B
    0x4A003570 0x0001000A
    0x4A003574 0x0004000C
    0x4A003578 0x0002000D
    0x4A00357C 0x0002000D
    0x4A003580 0x0006000B
    0x4A003584 0x0002000B
    0x4A003588 0x0002000B
    0x4A00358C 0x0002000B
    0x4A003590 0x0000000B
    0x4A003594 0x0005000B
    0x4A003598 0x00000103
    0x4A00359C 0x00000103
    0x4A0035A0 0x00000103
    0x4A0035A4 0x00000103
    0x4A0035A8 0x00000103
    0x4A0035AC 0x00000103
    0x4A0035B0 0x00040103
    0x4A0035B4 0x00040103
    0x4A0035B8 0x00060103
    0x4A0035BC 0x00060103
    0x4A0035C0 0x00060103
    0x4A0035C4 0x00060103
    0x4A0035C8 0x0004000F
    0x4A0035CC 0x0004000F
    0x4A0035D0 0x0001000E
    0x4A0035D4 0x0004000F
    0x4A0035D8 0x0006000C
    0x4A0035DC 0x0006000C
    0x4A0035E0 0x0004000C
    0x4A0035E4 0x0006000C
    0x4A0035E8 0x0004000C
    0x4A0035EC 0x0004000C
    0x4A0035F0 0x0004000C
    0x4A0035F4 0x0004000C
    0x4A0035F8 0x0004000C
    0x4A0035FC 0x0006000C
    0x4A003600 0x0002000D
    0x4A003604 0x0002000D
    0x4A003608 0x0002000D
    0x4A00360C 0x0002000D
    0x4A003610 0x0002000D
    0x4A003614 0x0006000C
    0x4A003618 0x0004000C
    0x4A00361C 0x0004000C
    0x4A003620 0x0004000C
    0x4A003624 0x0004000C
    0x4A003628 0x0004000C
    0x4A00362C 0x0006000C
    0x4A003630 0x0004000C
    0x4A003634 0x0004000C
    0x4A003638 0x0004000C
    0x4A00363C 0x00080000
    0x4A003640 0x000D0000
    0x4A003644 0x0004000F
    0x4A003648 0x000A000E
    0x4A00364C 0x0008000E
    0x4A003650 0x00000100
    0x4A003654 0x00000100
    0x4A003658 0x00000100
    0x4A00365C 0x00000100
    0x4A003660 0x00000100
    0x4A003664 0x00000100
    0x4A003668 0x00040100
    0x4A00366C 0x00040100
    0x4A003670 0x00060100
    0x4A003674 0x00060100
    0x4A003678 0x00060100
    0x4A00367C 0x00060100
    0x4A003680 0x00090000
    0x4A003684 0x00090000
    0x4A003688 0x00010000
    0x4A00368C 0x00010000
    0x4A003690 0x00060000
    0x4A003694 0x0004000B
    0x4A003698 0x0004000B
    0x4A00369C 0x0001000E
    0x4A0036A0 0x00050007
    0x4A0036A4 0x0000000B
    0x4A0036A8 0x000D000B
    0x4A0036AC 0x0005000E
    0x4A0036B0 0x0005000E
    0x4A0036B4 0x000E000B
    0x4A0036B8 0x000E000B
    0x4A0036BC 0x0005000E
    0x4A0036C0 0x0005000E
    0x4A0036C4 0x0004000E
    0x4A0036C8 0x0005000E
    0x4A0036CC 0x0001000E
    0x4A0036D0 0x0001000E
    0x4A0036D4 0x000A000B
    0x4A0036D8 0x000A000B
    0x4A0036DC 0x000A000B
    0x4A0036E0 0x000A000B
    0x4A0036E4 0x000A000B
    0x4A0036E8 0x000E000B
    0x4A0036EC 0x000C000B
    0x4A0036F0 0x000C000B
    0x4A0036F4 0x0004000B
    0x4A0036F8 0x000C000B
    0x4A0036FC 0x0004000F
    0x4A003700 0x0004000F
    0x4A003704 0x0004000F
    0x4A003708 0x0004000F
    0x4A00370C 0x000C000B
    0x4A003710 0x000C000B
    0x4A003714 0x0001000E
    0x4A003718 0x0001000E
    0x4A00371C 0x0001000E
    0x4A003720 0x0001000E
    0x4A003724 0x0004000B
    0x4A003728 0x000C000B
    0x4A00372C 0x000E000B
    0x4A003730 0x000E000B
    0x4A003734 0x00010002
    0x4A003738 0x00050002
    0x4A00373C 0x0004000F
    0x4A003740 0x00020002
    0x4A003744 0x0004000F
    0x4A003748 0x0004000F
    0x4A00374C 0x00050004
    0x4A003750 0x00010004
    0x4A003754 0x00060000
    0x4A003758 0x00060000
    0x4A00375C 0x00060000
    0x4A003760 0x00060000
    0x4A003764 0x00060000
    0x4A003768 0x00060000
    0x4A00376C 0x000D000E
    0x4A003770 0x000D000E
    0x4A003774 0x0006000B
    0x4A003778 0x0002000B
    0x4A00377C 0x0002000B
    0x4A003780 0x0002000B
    0x4A003784 0x0002000B
    0x4A003788 0x0002000B
    0x4A00378C 0x0006000B
    0x4A003790 0x0004000B
    0x4A003794 0x0004000B
    0x4A003798 0x0004000B
    0x4A00379C 0x0004000B
    0x4A0037A0 0x0004000B
    0x4A0037A4 0x0001000E
    0x4A0037A8 0x0001000E
    0x4A0037AC 0x0001000E
    0x4A0037B0 0x0001000E
    0x4A0037B4 0x0001000E
    0x4A0037B8 0x000C000E
    0x4A0037BC 0x000D0006
    0x4A0037C0 0x00050000
    0x4A0037C4 0x000D0000
    0x4A0037C8 0x000D0000
    0x4A0037CC 0x000D0000
    0x4A0037D0 0x0002000F
    0x4A0037D4 0x0002000F
    0x4A0037E0 0x00060000
    0x4A0037E4 0x00010000
    0x4A0037E8 0x0006000F
    0x4A0037EC 0x0006000F
    0x4A0037F0 0x0006000F
    0x4A0037F4 0x0006000F
    0x4A0037F8 0x000C0002
    0x4A0037FC 0x000C0001
    0x4A003800 0x00050000
    0x4A003804 0x00050000
    0x4A003808 0x00050001
    0x4A00380C 0x00050001
    0x4A003818 0x00010000
    0x4A003824 0x00010000
    0x4A003828 0x00010000
    0x4A00382C 0x00010000
    0x4A003830 0x00060000
    0x4A003834 0x000E0000
    0x4A003838 0x00020000
    0x4A00383C 0x00060000
    0x4A003840 0x00050000
    0x4A003844 0x00020000
    0x4A003848 0x00050000
    0x4A00384C 0x00050000
    0x4A00385C 0x00010000
    0x4A003860 0x00000000
    0x4A003864 0x00010000
    


    Regards,
    Suresh


  • How have you configured pruss2 in your device tree?  Can you please share some snippets?  Did you configure ti,pruss-gp-mux-sel?

    When you built your hardware, did you model after specific TI board?  If so, which specifically?  There are some subtle differences between AM572x IDK and AM571x IDK related to the Ethernet hookup.  We need to make sure the hardware and software are consistent.

  • Hi Mr.Brad,

    Yes, we have followed the AM5718 EVK to built our custom platform. Please find the uploaded PRUSS2 configuration screenshots for your reference.

    Files: DTS_File_PRUSS2_ScreenShots.zip

    For your information, the same S/W binary working correctly in AM5718 EVK(IP assigned & able ping the host) but not worked in our custom board(IP not assigned). Could you help us conclude this issue ASAP.


    Regards,
    Suresh 

  • Hello Suresh,

    I apologize for the delay.

    1) Is this correct?: you only have two ethernet ports: eth0 and eth1. Those relate to pruss2_eth0_phy and pruss2_eth1_phy in the dts files.

    2) Are you trying to assign an IP address through DHCP, statically, or some other way?

    3) Can you manually assign an IP address and ping or iperf with the port? e.g., if your computer's ethernet port is 192.168.1.1:

    ifconfig eth0 192.168.1.2 (assign it an IP address with the same subnet)

    Regards,

    Nick