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.

TDA4VM: TDA4VM: 移植phy无法获取ip

Part Number: TDA4VM


hi,

我们在sdk 8.4

ti-processor-sdk-rtos-j721e-evm-08_04_00_02中移植phy,phy已经处于linked状态,但是无法获取ip,按如下方法设置静态IP,也无法ping通

我们的phy已在7.3的sdk中将功能调通,升级sdk8。4后出现此问题,pinmux,rgmii mode都是正确的


root@j7-evm:~/dltlogs#
root@j7-evm:~/dltlogs# devmem2 0x00011C100
/dev/mem opened.
Memory mapped at address 0xffffaa804000.
Read at address 0x0011C100 (0xffffaa804100): 0x00050004
root@j7-evm:~/dltlogs# devmem2 0x00011C104
/dev/mem opened.
Memory mapped at address 0xffffa2bf1000.
Read at address 0x0011C104 (0xffffa2bf1104): 0x00050004
root@j7-evm:~/dltlogs# devmem2 0x00011C108
/dev/mem opened.
Memory mapped at address 0xffffbc017000.
Read at address 0x0011C108 (0xffffbc017108): 0x00050004
root@j7-evm:~/dltlogs# devmem2 0x00011C10c
/dev/mem opened.
Memory mapped at address 0xffffaadf0000.
Read at address 0x0011C10C (0xffffaadf010c): 0x00050004
root@j7-evm:~/dltlogs# devmem2 0x00011C118
/dev/mem opened.
Memory mapped at address 0xffff84056000.
Read at address 0x0011C118 (0xffff84056118): 0x00050004
root@j7-evm:~/dltlogs# devmem2 0x00011C110
/dev/mem opened.
Memory mapped at address 0xffff81291000.
Read at address 0x0011C110 (0xffff81291110): 0x00050004
root@j7-evm:~/dltlogs# devmem2 0x00011C12c
/dev/mem opened.
Memory mapped at address 0xffff88dfa000.
Read at address 0x0011C12C (0xffff88dfa12c): 0x00010004
root@j7-evm:~/dltlogs# devmem2 0x00011C130
/dev/mem opened.
Memory mapped at address 0xffffacbc9000.
Read at address 0x0011C130 (0xffffacbc9130): 0x00010004
root@j7-evm:~/dltlogs# devmem2 0x00011C134
/dev/mem opened.
Memory mapped at address 0xffffb42ef000.
Read at address 0x0011C134 (0xffffb42ef134): 0x00010004
root@j7-evm:~/dltlogs# devmem2 0x00011C140
/dev/mem opened.
Memory mapped at address 0xffffbb52f000.
Read at address 0x0011C140 (0xffffbb52f140): 0x00010004
root@j7-evm:~/dltlogs# devmem2 0x00011C13c
/dev/mem opened.
Memory mapped at address 0xffff92079000.
Read at address 0x0011C13C (0xffff9207913c): 0x00010004
root@j7-evm:~/dltlogs# devmem2 0x104050
/dev/mem opened.
Memory mapped at address 0xffff8665f000.
Read at address 0x00104050 (0xffff8665f050): 0x00000012

phy

phy-BCM89610A2BMLG与88Q2112都不能ping通(设置静态ip)

  • 已重新打开e2e帖子,把您的问题更新到帖子上了。

  • 请问一下,什么时候可以回复下,这个已经block很久了

  • 抱歉回复晚了,下面是e2e工程师的回复。

    Is the customer able to read/write phy registers?

    If he is able to, can you check the tx and rx error count register in the phy address space if they are incrementing?

  •  我们可以通过mdio读取到phy, id,且phy显示连接上了,对应的125M clk也有,但是mac的tx量到波型给phy,phy有波型到mac(接上网线后)

  • 但是mac的tx量到波型给phy,phy有波型到mac(接上网线后)

    这里都有波形是吗?

    If he is able to, can you check the tx and rx error count register in the phy address space if they are incrementing?

    这个问题能回复一下么?

  • mac的tx量到没有波型给phy,phy有波型到mac

  • mac的tx量到没有波形送到phy,phy有波形送到mac

  • 我们将

    BCM89610A2BMLG 移植到linux代码中,eth0出来,设置静态ip,发现好像也同样存在不能ping通,采用tcpdump发现也只能接收不能发送的情况,能接收到来自路由器的信号,但IP不是本机,

  • linux 中mcu2-0采用的dts节点是mcu_cpsw: ethernet@46000000

  • 已把您的回复更新到e2e帖子上,请关注工程师的回复。

  • 请看下面e2e工程师的回复。

    Can you share the ethernet controller stats. You can get them by running "ethtool -S eth0" on linux command line.

    Also, We can try the MAC loopback test to ensure the MAC is working correctly or not first.

    To do this, follow the following steps :

    • Read the register at address : 0x46022330
      • you can read a register in linux using command "devmem2 0x46022330"
    • Add 2 to the value read and write it back to the same register
      • you can write to a register in linux using command "devmem2 0x46022330 w ${original value + 2}"

    To test the MAC, run the following commands

    • ethtool -S eth0 | grep good
    • Do a ping for 5-10 seconds
    • ethtool -S eth0 | grep good

    Please share the output of the test with me.

    If this is successful, please try the phy loopback test as well.

  • 好的,

    BCM89610A2BMLG 移植到linux代码中,eth0出来,设置静态ip,发现好像也同样存在不能ping通,采用tcpdump发现也只能接收不能发送的情况,能接收到来自路由器的信号,但IP不是本机

    这个在linux调试BCM89610A2BMLG  phy我们这边已经通了,但我们在rtos上调试不通

  • 这个在linux调试BCM89610A2BMLG  phy(mcu 域 2G)我们这边已经通了,但我们在rtos上调试不通

  • 已把您的回复更新到e2e帖子,请关注帖子的回复。

  • 请看下面e2e工程师的回复。

    I am confused now about the setup, I assumed the earlier setup. 

    Can you share a block diagram of the system and different experiments tried and the working and non working links.

    Also, for wherever is not working, can you do a MAC loopback test. You can find steps on how to do the test here.

  • shine,晚点验证后回复你,最近在出差中

  • Can you share the ethernet controller stats. You can get them by running "ethtool -S eth0" on linux command line.

    Also, We can try the MAC loopback test to ensure the MAC is working correctly or not first.

    To do this, follow the following steps :

    • Read the register at address : 0x46022330
      • you can read a register in linux using command "devmem2 0x46022330"
    • Add 2 to the value read and write it back to the same register
      • you can write to a register in linux using command "devmem2 0x46022330 w ${original value + 2}"

    To test the MAC, run the following commands

    • ethtool -S eth0 | grep good
    • Do a ping for 5-10 seconds
    • ethtool -S eth0 | grep good

    Please share the output of the test with me.

    If this is successful, please try the phy loopback test as well.

    result fail:

    test

    root@j7-evm:/lib/modules/5.10.120/kernel/drivers/net/ethernet/ti# ifconfig
    eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 metric 1
    inet6 fe80::72ff:76ff:fe1d:92c1 prefixlen 64 scopeid 0x20<link>
    ether 70:ff:76:1d:92:c1 txqueuelen 1000 (Ethernet)
    RX packets 0 bytes 0 (0.0 B)
    RX errors 0 dropped 0 overruns 0 frame 0
    TX packets 19 bytes 3060 (2.9 KiB)
    TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

    eth1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 metric 1
    inet6 fe80::72ff:76ff:fe1d:92c2 prefixlen 64 scopeid 0x20<link>
    ether 70:ff:76:1d:92:c2 txqueuelen 1000 (Ethernet)
    RX packets 0 bytes 0 (0.0 B)
    RX errors 0 dropped 0 overruns 0 frame 0
    TX packets 18 bytes 2730 (2.6 KiB)
    TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

    lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536 metric 1
    inet 127.0.0.1 netmask 255.0.0.0
    inet6 ::1 prefixlen 128 scopeid 0x10<host>
    loop txqueuelen 1000 (Local Loopback)
    RX packets 82 bytes 6220 (6.0 KiB)
    RX errors 0 dropped 0 overruns 0 frame 0
    TX packets 82 bytes 6220 (6.0 KiB)
    TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

    root@j7-evm:/lib/modules/5.10.120/kernel/drivers/net/ethernet/ti# devmem2 0x46022330
    /dev/mem opened.
    Memory mapped at address 0xffffb010c000.
    Read at address 0x46022330 (0xffffb010c330): 0x00000000
    root@j7-evm:/lib/modules/5.10.120/kernel/drivers/net/ethernet/ti# devmem2 0x46022330 w 0x00000002
    /dev/mem opened.
    Memory mapped at address 0xffff81c8e000.
    Read at address 0x46022330 (0xffff81c8e330): 0x00000000
    Write at address 0x46022330 (0xffff81c8e330): 0x00000002, readback 0x00000002
    root@j7-evm:/lib/modules/5.10.120/kernel/drivers/net/ethernet/ti# ethtool -S eth0 | grep good
    no stats available
    root@j7-evm:/lib/modules/5.10.120/kernel/drivers/net/ethernet/ti# ifconfig
    eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 metric 1
    inet6 fe80::72ff:76ff:fe1d:92c1 prefixlen 64 scopeid 0x20<link>
    ether 70:ff:76:1d:92:c1 txqueuelen 1000 (Ethernet)
    RX packets 233 bytes 21701 (21.1 KiB)
    RX errors 0 dropped 0 overruns 0 frame 0
    TX packets 29 bytes 5190 (5.0 KiB)
    TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

    eth1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 metric 1
    inet6 fe80::72ff:76ff:fe1d:92c2 prefixlen 64 scopeid 0x20<link>
    ether 70:ff:76:1d:92:c2 txqueuelen 1000 (Ethernet)
    RX packets 0 bytes 0 (0.0 B)
    RX errors 0 dropped 0 overruns 0 frame 0
    TX packets 30 bytes 5260 (5.1 KiB)
    TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

    lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536 metric 1
    inet 127.0.0.1 netmask 255.0.0.0
    inet6 ::1 prefixlen 128 scopeid 0x10<host>
    loop txqueuelen 1000 (Local Loopback)
    RX packets 82 bytes 6220 (6.0 KiB)
    RX errors 0 dropped 0 overruns 0 frame 0
    TX packets 82 bytes 6220 (6.0 KiB)
    TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

    root@j7-evm:/lib/modules/5.10.120/kernel/drivers/net/ethernet/ti# ifconfig eth0 192.168.2.124
    root@j7-evm:/lib/modules/5.10.120/kernel/drivers/net/ethernet/ti# ifconfig eth0 192.168.2.124 up
    root@j7-evm:/lib/modules/5.10.120/kernel/drivers/net/ethernet/ti# ifconfig
    eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 metric 1
    inet 192.168.2.124 netmask 255.255.255.0 broadcast 192.168.2.255
    inet6 fe80::72ff:76ff:fe1d:92c1 prefixlen 64 scopeid 0x20<link>
    ether 70:ff:76:1d:92:c1 txqueuelen 1000 (Ethernet)
    RX packets 265 bytes 24599 (24.0 KiB)
    RX errors 0 dropped 0 overruns 0 frame 0
    TX packets 41 bytes 7028 (6.8 KiB)
    TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

    eth1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 metric 1
    inet6 fe80::72ff:76ff:fe1d:92c2 prefixlen 64 scopeid 0x20<link>
    ether 70:ff:76:1d:92:c2 txqueuelen 1000 (Ethernet)
    RX packets 0 bytes 0 (0.0 B)
    RX errors 0 dropped 0 overruns 0 frame 0
    TX packets 30 bytes 5260 (5.1 KiB)
    TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

    lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536 metric 1
    inet 127.0.0.1 netmask 255.0.0.0
    inet6 ::1 prefixlen 128 scopeid 0x10<host>
    loop txqueuelen 1000 (Local Loopback)
    RX packets 82 bytes 6220 (6.0 KiB)
    RX errors 0 dropped 0 overruns 0 frame 0
    TX packets 82 bytes 6220 (6.0 KiB)
    TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

    root@j7-evm:/lib/modules/5.10.120/kernel/drivers/net/ethernet/ti# ping 192.168.2.1
    PING 192.168.2.1 (192.168.2.1): 56 data bytes

    ^C
    --- 192.168.2.1 ping statistics ---
    50 packets transmitted, 0 packets received, 100% packet loss
    root@j7-evm:/lib/modules/5.10.120/kernel/drivers/net/ethernet/ti# ^C
    root@j7-evm:/lib/modules/5.10.120/kernel/drivers/net/ethernet/ti# ethtool -S eth0 | grep good
    no stats available
    root@j7-evm:/lib/modules/5.10.120/kernel/drivers/net/ethernet/ti#

  • 已跟进帖子。