Query regarding MAC address configuration for S32G PFE

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

Query regarding MAC address configuration for S32G PFE

2,101 次查看
Sandeep_ME
Contributor I

Hello,

We are using S32G in our project with M7 as PFE Master and A53 as Slave.
I would like to know, when we configure a MAC address in Tresos EthCtrlPhyAddress parameter, where it is associated to - for a given EMAC configured in EthCtrlHwPort OR just an M7/A53's instance of the EMAC2? For example, if EthCtrlHwPort is set as EMAC2, then will EMAC2 be having this address, irrespective of which core is using this controller?

Subsequent question: If I want to use the same EMAC2 from M7 as well as A53 using a L2 Bridge on the same VLAN, can I associate different MAC addresses for the same EMAC2, one in M7 and one in A53? Will PFE be able to gateway the traffic based on respective MAC?

From the documentation, its a bit confusing how the MAC addresses are handled.
Hence can you please clarify?


MCAL user manual 6.1.1.:

Sandeep_ME_0-1732119947962.png

Tresos:

Sandeep_ME_1-1732120042715.png

 

0 项奖励
回复
5 回复数

2,070 次查看
Sandeep_ME
Contributor I

Hi @alejandro_e,

AFAIK S32G has 4 Ethernet MAC - 3 inside PFE and one GMAC.
My query is regarding EMACs inside PFE and not the GMAC which you have mentioned in the reply.

Please check the query and provide a feedback from PFE point of view, as the MAC address handling is different between GMAC and PFE.

Sandeep_ME_0-1732180809225.pngSandeep_ME_1-1732180858489.png

 

0 项奖励
回复

2,062 次查看
alejandro_e
NXP TechSupport
NXP TechSupport

Hello @Sandeep_ME,

I apologize for not clarifying , all the EMACs (in GMAC or PFE) use the same register interface.

Let me know if you have more questions about this topic.

 

Best regards,

Alejandro

0 项奖励
回复

2,041 次查看
Sandeep_ME
Contributor I

Hello @alejandro_e ,

Unfortunately it still doesn't answer my question

The manual screenshot which you shared doesn't explain which MAC address is taken when two cores use the same EMAC.

From the configuration point of view, for the same EMAC2 we can configure in NXP's MCAL on M7(PFE master) one static MAC address and from A53(PFE Slave) we can configure a totally different static MAC address in the same build , as shown in below screenshot.
There is no error raised.

In this case how do we find out(without testing), where and how each of this MAC address is associated to and taken during runtime? 
Is it that M7 traffic will use the MAC address configured in Tresos and A53 traffic will use its MAC address as in the patch file, inspite of using the same EMAC?

Sandeep_ME_0-1732288482477.png

Sandeep_ME_1-1732288498355.png

 

Sandeep_ME_2-1732288538156.png

 

 

0 项奖励
回复

2,032 次查看
alejandro_e
NXP TechSupport
NXP TechSupport

Hello @Sandeep_ME,

I understand your question better now, the logic of which MAC address is used when configuring a devices as a master-slave is defined in the PFE MCAL User Manual [page 150, User Manual for S32G PFE MCAL 4.4 Driver, Rev0000R1.4.0 Rev. 2.5]:

alejandro_e_0-1732307929484.png

 

For more details please check Chapter 6, particularly subsection 6.1.1.1 Running multiple PFE drivers of the mentioned document.

 

Let me know if this information answers your questions.

 

 

0 项奖励
回复

2,085 次查看
alejandro_e
NXP TechSupport
NXP TechSupport

Hello @Sandeep_ME,

According to the GMAC Reference manual [page 3, GMAC Subsystem RM, Rev. 2, 03/2021] the MAC address is saved in the following registers:

alejandro_e_0-1732126996504.png

You can check the details starting in page 149:

alejandro_e_1-1732127030941.png

 

The logic of which MAC address is used is given in pages 37 and 38:

alejandro_e_2-1732127084678.png

 

The value being in a register means all cores will use the same MAC address when using the module unless the configuration is change during runtime.

 

Let me know if this information solved your question.

0 项奖励
回复