尊敬的专家
我使用 CPSW9G 模块上的端口6连接到千兆位 PHY KSZ9031、然后连接到 PC。 连接关系如下所示。

PC 和 A72无法彼此 Ping。 但我发现、当 PC Ping A72时、A72可以接收 ARP 消息、但 PC 无法接收到响应。
能帮我看看 A72是否尚未发送数据或者它是否被阻止了吗? 谢谢你。


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.
尊敬的专家
我使用 CPSW9G 模块上的端口6连接到千兆位 PHY KSZ9031、然后连接到 PC。 连接关系如下所示。

PC 和 A72无法彼此 Ping。 但我发现、当 PC Ping A72时、A72可以接收 ARP 消息、但 PC 无法接收到响应。
能帮我看看 A72是否尚未发送数据或者它是否被阻止了吗? 谢谢你。


1.PSDK ROTS 08_04_00_06
PSDK Linux 08_04_00_11
2. 这里是我的更改:
我使用了 cpsw9g 的 port6,也在内核 DTS 下进行了相应的修改。
e2e.ti.com/.../3718.change.diffe2e.ti.com/.../dummy.c
此 PHY 在通电后进行初始化、不需要软件来配置 PHY 寄存器。 因此、在 MCU 2.0的固件中、我已返回有关 将 phy 寄存器读取为 true 的所有操作。
我们的电路设计存在问题。 MDIO 总线不使用 cpsw9g、而是使用 cpsw2g。 我可以在内核中使用 cpsw2g 的 MDIO 总线读取 phy 的寄存器值。 phy 寄存器1的值为0x796d、表示它已链接。
您好!
您必须从"gEthApp_VirtPortCfg"将端口6映射到以太网固件中的 MPU1_0、默认情况下端口1作为仅 MAC 端口映射到 MAPU1_0
static EthFw_VirtPortCfg gEthApp_virtPortCfg[] ={ { .remoteCoreId = IPC_MPU1_0, .portId = ETHREMOTECFG_SWITCH_PORT_0, }, { .remoteCoreId = IPC_MCU2_1, .portId = ETHREMOTECFG_SWITCH_PORT_1, },#if defined(ENABLE_MAC_ONLY_PORTS) { .remoteCoreId = IPC_MPU1_0, - .portId = ETHREMOTECFG_MAC_PORT_1, + .portId = ETHREMOTECFG_MAC_PORT_6, }, { .remoteCoreId = IPC_MCU2_1, .portId = ETHREMOTECFG_MAC_PORT_4, },#endif};请在 EthFW 中进行上述更改并重新编译映像、使用最新的二进制文件并确认 ping 是否可以正常工作。
有关配置 仅 MAC 端口的更多详细信息、请参阅用户指南。
此致、
苏德黑尔
您好!
您能否分享 EthFW 日志以及以下信息?
PC 侧和 A72侧的 ifconfig 输出。
2.在 EthFW 端执行以下命令来收集统计数据。
# ethtool -t
3.从 A72运行 ping 命令,并使用 tcpdump 和 Wireshark 在 A72和 PC 端转储数据包信息
4.通过执行步骤2在 EthFW 端收集统计数据。
此外、您能否分享您身边所有的代码更改。
此外、您是否可以尝试如下所示将 phyaddr 配置为"Invalid PHY"、因为您未使用 MDIO 配置 PHY。
+.phyCfg =
+{
-.pyAddr = 7u、
+ phyAddr = ENETPHY_INVALID_PHYADDR、
+.isStraped = false、
+.skipExtendedCfg = false
此致、
苏德黑尔
您好!
这是我的全部代码、删除之前被移植的 Tja1101以避免任何影响。
很抱歉、由于 温度测试、我需要等待几天才能进行测试
您好!
很抱歉这么晚才回复、
PC 侧和 A72侧的 ifconfig 输出。

2.通过在 A72端执行以下命令,在 EthFW 端收集统计信息。# ethtool -t

3.从 A72运行 ping 命令,并使用 tcpdump 和 Wireshark 在 A72和 PC 端转储数据包信息
[MCU2_0] 229.142475 s: 0: POLICER_DST_MAC,ALE Index: 9 [MCU2_0] 229.142519 s: 0: POLICER_ETHERTYPE,ALE Index: 11 [MCU2_0] 229.142564 s: 0: POLICER_THREAD,THREAD ID:3 [MCU2_0] 229.142620 s: 0: POLICER_STATS: Hit: 0, RedHit: 0, YellowHit: 0 [MCU2_0] 229.142676 s: 1: POLICER_PORT, PORT_NUM: 6 ISTRUNK:0 [MCU2_0] 229.142720 s: 1: POLICER_THREAD,THREAD ID:0 [MCU2_0] 229.142769 s: 1: POLICER_STATS: Hit: 1, RedHit: 0, YellowHit: 0 [MCU2_0] 229.143096 s: [MCU2_0] 229.143134 s: 94 Free Entries [MCU2_0] 229.143231 s: [MCU2_0] Port 0 Statistics [MCU2_0] 229.143261 s: ----------------------------------------- [MCU2_0] 229.143321 s: rxGoodFrames = 48 [MCU2_0] 229.143372 s: rxBcastFrames = 17 [MCU2_0] 229.143412 s: rxMcastFrames = 31 [MCU2_0] 229.143452 s: aleDrop = 7 [MCU2_0] 229.143490 s: rxOctets = 9642 [MCU2_0] 229.143528 s: txGoodFrames = 9 [MCU2_0] 229.143566 s: txBcastFrames = 1 [MCU2_0] 229.143603 s: txMcastFrames = 8 [MCU2_0] 229.143642 s: txOctets = 2015 [MCU2_0] 229.143680 s: octetsFrames65to127 = 22 [MCU2_0] 229.143718 s: octetsFrames128to255 = 18 [MCU2_0] 229.143756 s: octetsFrames256to511 = 17 [MCU2_0] 229.143846 s: netOctets = 11657 [MCU2_0] 229.143889 s: portMaskDrop = 7 [MCU2_0] 229.143938 s: txPri[0] = 9 [MCU2_0] 229.143985 s: txPriBcnt[0] = 2015 [MCU2_0] 229.144017 s: [MCU2_0] 229.144114 s: [MCU2_0] External Port 0 Statistics [MCU2_0] 229.144151 s: ----------------------------------------- [MCU2_0] 229.144195 s: [MCU2_0] 229.144283 s: [MCU2_0] External Port 1 Statistics [MCU2_0] 229.144318 s: ----------------------------------------- [MCU2_0] 229.144354 s: [MCU2_0] 229.144432 s: [MCU2_0] External Port 2 Statistics [MCU2_0] 229.144465 s: ----------------------------------------- [MCU2_0] 229.144499 s: [MCU2_0] 229.144577 s: [MCU2_0] External Port 3 Statistics [MCU2_0] 229.144610 s: ----------------------------------------- [MCU2_0] 229.144642 s: [MCU2_0] 229.144719 s: [MCU2_0] External Port 4 Statistics [MCU2_0] 229.144752 s: ----------------------------------------- [MCU2_0] 229.144832 s: [MCU2_0] 229.144924 s: [MCU2_0] External Port 5 Statistics [MCU2_0] 229.144960 s: ----------------------------------------- [MCU2_0] 229.145013 s: rxGoodFrames = 9 [MCU2_0] 229.145053 s: rxBcastFrames = 1 [MCU2_0] 229.145090 s: rxMcastFrames = 8 [MCU2_0] 229.145128 s: rxOctets = 2015 [MCU2_0] 229.145167 s: txGoodFrames = 41 [MCU2_0] 229.145205 s: txBcastFrames = 10 [MCU2_0] 229.145242 s: txMcastFrames = 31 [MCU2_0] 229.145280 s: txOctets = 7164 [MCU2_0] 229.145321 s: octetsFrames65to127 = 22 [MCU2_0] 229.145360 s: octetsFrames128to255 = 18 [MCU2_0] 229.145400 s: octetsFrames256to511 = 10 [MCU2_0] 229.145439 s: netOctets = 9179 [MCU2_0] 229.145480 s: aleUnknownMcast = 8 [MCU2_0] 229.145518 s: aleUnknownMcastBcnt = 1768 [MCU2_0] 229.145556 s: aleUnknownBcast = 1 [MCU2_0] 229.145593 s: aleUnknownBcastBcnt = 247 [MCU2_0] 229.145630 s: alePolicyMatch = 9 [MCU2_0] 229.145673 s: txPri[0] = 41 [MCU2_0] 229.145716 s: txPriBcnt[0] = 7164 [MCU2_0] 229.145746 s: [MCU2_0] 229.145868 s: [MCU2_0] External Port 6 Statistics [MCU2_0] 229.145911 s: ----------------------------------------- [MCU2_0] 229.145951 s: [MCU2_0] 229.146038 s: [MCU2_0] External Port 7 Statistics [MCU2_0] 229.146074 s: ----------------------------------------- [MCU2_0] 229.146110 s: [MCU2_1] 3.428190 s: CIO: Init ... Done !!! [MCU2_1] 3.428257 s: ### CPU Frequency = 1000000000 Hz [MCU2_1] 3.428301 s: APP: Init ... !!! [MCU2_1] 3.428330 s: SCICLIENT: Init ... !!! [MCU2_1] 3.428592 s: SCICLIENT: DMSC FW version [8.4.1--v08.04.01 (Jolly Jellyfi]

4.通过执行步骤2在 EthFW 端收集统计数据。
5. 从 PC ping 命令并在 a72转储数据包

尊敬的 Ling:
我看到 txGoodFrames/rxGoodFrames/rxGoodFrames 有增加
正确、我们可以看到 Port-0 (内部主机端口)统计信息和 External Port-5 (MAC Port-6)统计信息。
主机端口的 TX 与外部端口的 Rx 相同、其中主机端口的 Rx +主机端口的部分 Ale 中断将与外部端口的 Tx 相同。
从统计数据来看、CPSW 似乎正在接收和传输数据包。
cpsw9g TX/Rx 是否正确?
有硬件统计信息。 SW 读取计数器并对其进行跟踪。
此致、
苏德黑尔