shared MAC between USDPAA and Linux

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

shared MAC between USDPAA and Linux

743 Views
liujianbo
Contributor II

Hi Yiping:

With SDK 1.7, We use shared MAC between USDPAA and Linux on B4860 target, change dts as the following:

/*********************************************************************/

ethernet@1 {

                         compatible = "fsl,b4860-dpa-ethernet-shared", "fsl,dpa-ethernet-shared";

                         fsl,fman-mac = <0x2f>;

                         fsl,bman-buffer-pools = <0x37>;

                         fsl,qman-frame-queues-rx = <0x52 0x1 0x53 0x1 0x2110 0x1>;

                         fsl,qman-frame-queues-tx = <0x72 0x1 0x73 0x1 0x3110 0x1>;

                 };

/*********************************************************************/

And use fmc tool to allocate and config buffer pools for shared MAC interface just as your mentioned in previous case(DPAA+shared interface )

Then bootup a L1 application.

But after several hours later, the board will crash(kernel failed to show any info and jtag tool can not dump register either at that moment)

Not sure if these steps have some problem, I failed to find doc(Freescale P4080/P5020/P3041 USDPAA IPFwd Longest Prefix Match User Manual) you mentioned in (I am going to test the DPAA driver for t1040,but I am new to this driver,so anyone can suggest me so... ), do you know where to get it?

And to debug dpaa driver in this situation, do you have some comments on it?

This issue happen with SDK1.7, do you know if the latest SDK 2.0 have fixed the similar issue?

Many thanks for your time!!!

yipingwang

Tags (3)
0 Kudos
1 Reply

501 Views
yipingwang
NXP TechSupport
NXP TechSupport

Hello Liu Jianbo,

For Shared MAC between USDPAA and Linux, you could refer to this document Shared-MAC and MAC-less Implementation in DPAA Linux Kernel Driver.

Please refer to the Shared MAC device node definition in the default device tree.

ethernet@9 {
compatible = "fsl,b4860-dpa-ethernet-shared", "fsl,dpa-ethernet-shared";
fsl,fman-mac = <&fm1mac10>;
fsl,bman-buffer-pools = <&bp17>;
fsl,qman-frame-queues-rx = <0x5e 1 0x5f 1 0x2000 3>;
fsl,qman-frame-queues-tx = <0 1 0 1 0x3000 8>;
};

• fsl,qman-frame-queues-rx - a list of base/count pairs of frame queues from which the Shared Driver dequeues frames.
Because the Shared Driver has a MAC device in its control, the device tree format of the frame queues is similar to the
Private Driver’s device tree format. The MAC device must have at least two types of frame queues specified at initialization. These are the error frame queue which is the frame queue on which received erroneous frames will be placed and the default frame queue which is the frame queue where the frame will be placed if no other frame queue is selected for transmission. The next batch represents the PCD queues. These queues will be used by the PCD rules configured by the user. The above device tree example defines one error queue with ID 0x5e, one default queue with ID 0x5f and 3 configurable PCD queues, 0x2000, 0x2001, 0x2002;


• fsl,qman-frame-queues-tx - a list of base/count pairs of frame queues used by the Shared Driver send the frames to the MAC device. As in Private DPAA Ethernet Driver, these are the TX error frame queue, TX confirmation frame queue and the standard TX frame queues. In the above example, a value of 0 for TX error and TX confirmation queues enables the dynamic allocation of values for queues’ IDs, letting the QMan assign available values. Besides one dynamic TX error and one dynamic TX confirmation queue, 8 standard TX queues will be created, with IDs between 0x3000 and 0x3007. It is recommended to specify up to NR_CPUs frame queues and have a direct mapping between frame queue and CPU. In the above example, B4860QDS has 8 CPUs.


Have a great day,
TIC

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

0 Kudos