Bus error interrupt on eTSEC DMA'ing

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

Bus error interrupt on eTSEC DMA'ing

跳至解决方案
1,123 次查看
romitchatterjee
Contributor V

I'm writing a Ethernet device driver for the LS1021A Tower board. Currently, I'm trying to use only eTSEC3 port with internal DMA and shared MDIO of eTSEC1. My interrupt handler is getting fired every time I try to do tx/rx with an EBERR error interrupt. I understand it is a bus error, but cannot figure out why it is occurring. I have already set up the TxBDs and RxBDs, as well as all the relevant registers (eTSEC3_TBDBPH, _RCTRL, DMACTRL etc.). I updated my code to use non-cacheable memory, but the behavior does not change. Is there something I'm missing during init/config? Do I need to do some SMMU3 related stuff (not doing any currently), like setting up the SCFG_MAC3_ICID and such?

标签 (1)
标记 (1)
1 解答
946 次查看
romitchatterjee
Contributor V

Thanks Platon,

That helped. I was actually setting the eTSECx_TBDBPH registers when they were not supposed to be. Removing that code made things work ok.

在原帖中查看解决方案

0 项奖励
2 回复数
947 次查看
romitchatterjee
Contributor V

Thanks Platon,

That helped. I was actually setting the eTSECx_TBDBPH registers when they were not supposed to be. Removing that code made things work ok.

0 项奖励
946 次查看
bpe
NXP Employee
NXP Employee

There are no reasons for EBERR other than bus errors. Note that
eTSEC DMA has no idea of the address translation done at MMU level,
so any pointers to memory in registers and BDs must be physical
addresses. Check RBPTR/TBPTR to see where the dedicated DMA

reads BDs, inspect the buffer pointed by the BDs at those addresses.

SMMU is disabled at reset, see the processor Reference
Manual, Section 9.4.8.1

Have a great day,
Platon

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------