S32K148 MCAL ENET EBERR 问题

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

S32K148 MCAL ENET EBERR 问题

跳至解决方案
1,324 次查看
fhz2000
Contributor II

您好 .遇到了问题.

以下是描述

目前正在配置S32K148-MCAL的Eth模块.

port中配置好pin脚

fhz2000_0-1726739311772.png

配置eth

fhz2000_1-1726739350182.png

生成代码后 组入

先调用eth_init

Eth_Init(&Eth_Config_VS_0);

随后使能控制器

Eth_SetControllerMode(EthConf_EthCtrlConfig_EthCtrlConfig_0, ETH_MODE_ACTIVE);

在此过程中

fhz2000_3-1726739557897.png

    Base->ECR |= ((uint32)(0x2U) | (0x100U));
    Base->ECR |= ((uint32)1U << (4U));
是可以正常配置ETHEREN为1的
fhz2000_5-1726740319507.png

 


但是一旦尝试初始化收发时,便会BUS ERROR

fhz2000_6-1726740363772.png

 

后续的发送更不可能了

请问我该如何继续调查

 

0 项奖励
回复
1 解答
1,261 次查看
PetrS
NXP TechSupport
NXP TechSupport

Hi,

you can check following.
- be sure user buffer and buffer descriptors are properly aligned and placed into non-cacheable area. ENET_RDSR and ENET_TDSR points to beginning of buffer descriptors rings.
- if MPU is enabled, be sure ENET master have access to memory area where user buffer and buffer descriptors are placed.

Some comments can be seen in https://community.nxp.com/t5/S32-SDK/The-ENET-module-of-S32K148-chip-failed-to-initialize-and-the/td...as well.

BR, Petr

在原帖中查看解决方案

4 回复数
1,300 次查看
fhz2000
Contributor II

问题进展更新 : 现在追查到MPU的 CESR 寄存器了.看起来好像是uDMA尝试访问内存时被内存保护察觉到并拦截了.

fhz2000_0-1726749164182.png

fhz2000_1-1726749178708.png

 

0 项奖励
回复
1,262 次查看
PetrS
NXP TechSupport
NXP TechSupport

Hi,

you can check following.
- be sure user buffer and buffer descriptors are properly aligned and placed into non-cacheable area. ENET_RDSR and ENET_TDSR points to beginning of buffer descriptors rings.
- if MPU is enabled, be sure ENET master have access to memory area where user buffer and buffer descriptors are placed.

Some comments can be seen in https://community.nxp.com/t5/S32-SDK/The-ENET-module-of-S32K148-chip-failed-to-initialize-and-the/td...as well.

BR, Petr

1,216 次查看
fhz2000
Contributor II
感谢 问题解决
0 项奖励
回复
1,217 次查看
fhz2000
Contributor II

感谢回复 问题已经 解决 原因是没配置MCAL的RM模块导致MPU模块没初始化ENET相关的内存访问权限

标记 (1)
0 项奖励
回复