[LS1046A][DPAA1] How to check DPAA1 is working?

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

[LS1046A][DPAA1] How to check DPAA1 is working?

Jump to solution
2,013 Views
alance
Contributor II

Hi

We'd like to set Ethernet port cross-connect using FMC as this thread. However, failed to get it work. There is no traffic seen on another port. Are there any ways to check DPAA PCD status? Thanks.

 

Here are my settings.

 

DTS

&fsldpaa {
ethernet@8 {
compatible = "fsl,dpa-ethernet";
fsl,qman-frame-queues-rx = <0x5c 1 0x5d 1 0x50 1>;
fsl,qman-frame-queues-tx = <0x7c 1 0x7d 1 0x70 1>;
dma-coherent;
};
ethernet@9 {
compatible = "fsl,dpa-ethernet";
fsl,qman-frame-queues-rx = <0x5e 1 0x5f 1 0x51 1>;
fsl,qman-frame-queues-tx = <0x7e 1 0x7f 1 0x71 1>;
fsl,fman-mac = <&enet7>;
dma-coherent;
};
};

 

cat /sys/devices/platform/soc/soc\:fsl\,dpaa/soc\:fsl\,dpaa\:ethernet\@8/net/fm1-mac9/fqids
Rx error: 92
Rx default: 93
Rx PCD: 80
Rx PCD High Priority: 65616
Tx confirmation (mq): 259 - 322
Tx error: 124
Tx default confirmation: 125
Tx: 112


root@localhost:~# cat /sys/devices/platform/soc/soc\:fsl\,dpaa/soc\:fsl\,dpaa\:ethernet\@9/net/fm1-mac10/fqids
Rx error: 94
Rx default: 95
Rx PCD: 81
Rx PCD High Priority: 65617
Tx confirmation (mq): 323 - 386
Tx error: 126
Tx default confirmation: 127
Tx: 113

 

 

config.xml

<cfgdata>
<config>
<engine name="fm0">
<port type="MAC" number="9" policy="fm_policy_9"/>
<port type="MAC" number="10" policy="fm_policy_10"/>
</engine>
</config>
</cfgdata>

 

policy_ipv4.xml

<distribution name="garbage_dist_9">
<queue count="1" base="0x71"/>
</distribution>

<distribution name="garbage_dist_10">
<queue count="1" base="0x70"/>
</distribution>

<policy name="fm_policy_9">
<dist_order>
<distributionref name="garbage_dist_9"/>
</dist_order>
</policy>

<policy name="fm_policy_10">
<dist_order>
<distributionref name="garbage_dist_10"/>
</dist_order>
</policy>

 

 

fmc -c config.xml -p policy_ipv4.xml -a -l dbg3

struct fmc_model_t cmodel = {
.format_version = 262,
.sp_enable = 0,
{
},

.fman_count = 1,
/* FMan: fm0 */
.fman[0].name = "fm0",
.fman[0].number = 0,
.fman[0].pcd_name = "fm0/pcd",
.fman[0].port_count = 2,
.fman[0].ports[0] =0,
.fman[0].ports[1] =1,

.fman[0].reasm_count = 0,

.fman[0].frag_count = 0,

.fman[0].hdr_count = 0,


.port_count = 2,
/* FMan port: fm0/port/MAC/9 */
.port[0].name = "fm0/port/MAC/9",
.port[0].cctree_name = "fm0/port/MAC/9/cctree",
.port[0].type =e_FM_PORT_TYPE_RX_10G,
.port[0].number = 0,
.port[0].schemes_count = 1,
.port[0].schemes[0] =0,
.port[0].vspParam.numOfProfiles = 0,
.port[0].vspParam.dfltRelativeId = 0,
.port[0].ccnodes_count = 0,
.port[0].htnodes_count = 0,
.port[0].replicators_count = 0,
.port[0].ccroot_count = 0,
.port[0].distinctionUnits.numOfDistinctionUnits = 0,
.port[0].pcdParam.pcdSupport = e_FM_PORT_PCD_SUPPORT_PRS_AND_KG,
.port[0].prsParam.parsingOffset = 0,
.port[0].prsParam.prsResultPrivateInfo = 0,
.port[0].prsParam.firstPrsHdr = HEADER_TYPE_ETH,
.port[0].reasm_index = 0,

/* FMan port: fm0/port/MAC/10 */
.port[1].name = "fm0/port/MAC/10",
.port[1].cctree_name = "fm0/port/MAC/10/cctree",
.port[1].type =e_FM_PORT_TYPE_RX_10G,
.port[1].number = 1,
.port[1].schemes_count = 1,
.port[1].schemes[0] =1,
.port[1].vspParam.numOfProfiles = 0,
.port[1].vspParam.dfltRelativeId = 0,
.port[1].ccnodes_count = 0,
.port[1].htnodes_count = 0,
.port[1].replicators_count = 0,
.port[1].ccroot_count = 0,
.port[1].distinctionUnits.numOfDistinctionUnits = 0,
.port[1].pcdParam.pcdSupport = e_FM_PORT_PCD_SUPPORT_PRS_AND_KG,
.port[1].prsParam.parsingOffset = 0,
.port[1].prsParam.prsResultPrivateInfo = 0,
.port[1].prsParam.firstPrsHdr = HEADER_TYPE_ETH,
.port[1].reasm_index = 0,


.scheme_count = 2,

/* Distribution: fm0/port/MAC/9/dist/garbage_dist_9 */
.scheme_name[0] = "fm0/port/MAC/9/dist/garbage_dist_9",
.scheme[0].alwaysDirect = 0,
.scheme[0].netEnvParams.numOfDistinctionUnits = 0,
.scheme[0].useHash = 0,
.scheme[0].baseFqid = 113,
.scheme[0].overrideStorageProfile = 0,
.scheme[0].nextEngine =e_FM_PCD_DONE,
.scheme[0].schemeCounter.update = 1,
.scheme[0].schemeCounter.value = 0,
.scheme[0].keyExtractAndHashParams.numOfUsedMasks = 0,
.scheme[0].keyExtractAndHashParams.hashShift = 0,
.scheme[0].keyExtractAndHashParams.symmetricHash = 0,
.scheme[0].keyExtractAndHashParams.hashDistributionNumOfFqids = 1,
.scheme[0].keyExtractAndHashParams.numOfUsedExtracts = 0,
.scheme[0].numOfUsedExtractedOrs = 0,

/* Distribution: fm0/port/MAC/10/dist/garbage_dist_10 */
.scheme_name[1] = "fm0/port/MAC/10/dist/garbage_dist_10",
.scheme[1].alwaysDirect = 0,
.scheme[1].netEnvParams.numOfDistinctionUnits = 0,
.scheme[1].useHash = 0,
.scheme[1].baseFqid = 112,
.scheme[1].overrideStorageProfile = 0,
.scheme[1].nextEngine =e_FM_PCD_DONE,
.scheme[1].schemeCounter.update = 1,
.scheme[1].schemeCounter.value = 0,
.scheme[1].keyExtractAndHashParams.numOfUsedMasks = 0,
.scheme[1].keyExtractAndHashParams.hashShift = 0,
.scheme[1].keyExtractAndHashParams.symmetricHash = 0,
.scheme[1].keyExtractAndHashParams.hashDistributionNumOfFqids = 1,
.scheme[1].keyExtractAndHashParams.numOfUsedExtracts = 0,
.scheme[1].numOfUsedExtractedOrs = 0,

.ccnode_count = 0,

.htnode_count = 0,

.replicator_count = 0,

.policer_count = 0,

.apply_order_count = 8,
FMC_APPLY_ORDER( 0, FMCEngineStart , 0 ), /* fm0 */
FMC_APPLY_ORDER( 1, FMCPortStart , 0 ), /* fm0/port/MAC/9 */
FMC_APPLY_ORDER( 2, FMCScheme , 0 ), /* fm0/port/MAC/9/dist/garbage_dist_9 */
FMC_APPLY_ORDER( 3, FMCPortEnd , 0 ), /* fm0/port/MAC/9 */
FMC_APPLY_ORDER( 4, FMCPortStart , 1 ), /* fm0/port/MAC/10 */
FMC_APPLY_ORDER( 5, FMCScheme , 1 ), /* fm0/port/MAC/10/dist/garbage_dist_10 */
FMC_APPLY_ORDER( 6, FMCPortEnd , 1 ), /* fm0/port/MAC/10 */
FMC_APPLY_ORDER( 7, FMCEngineEnd , 0 ), /* fm0 */
};

DBG1: Invocation of FM_PCD_Disable from fmc_clean_engine_end for fm0/pcd
DBG1: Invocation of FM_PCD_Disable for fm0/pcd succeeded
DBG1: Invocation of FM_PORT_DeletePCD from fmc_clean_port_end for fm0/port/MAC/10
DBG1: Invocation of FM_PORT_DeletePCD for fm0/port/MAC/10 succeeded
DBG1: Invocation of FM_PCD_KgSchemeDelete from fmc_clean_scheme for fm0/port/MAC/10/dist/garbage_dist_10
DBG1: Invocation of FM_PCD_KgSchemeDelete for fm0/port/MAC/10/dist/garbage_dist_10 succeeded
DBG1: Invocation of FM_PCD_NetEnvCharacteristicsDelete from fmc_clean_port_start for fm0/port/MAC/10
DBG1: Invocation of FM_PCD_NetEnvCharacteristicsDelete for fm0/port/MAC/10 succeeded
DBG1: Invocation of FM_PORT_DeletePCD from fmc_clean_port_end for fm0/port/MAC/9
DBG1: Invocation of FM_PORT_DeletePCD for fm0/port/MAC/9 succeeded
DBG1: Invocation of FM_PCD_KgSchemeDelete from fmc_clean_scheme for fm0/port/MAC/9/dist/garbage_dist_9
DBG1: Invocation of FM_PCD_KgSchemeDelete for fm0/port/MAC/9/dist/garbage_dist_9 succeeded
DBG1: Invocation of FM_PCD_NetEnvCharacteristicsDelete from fmc_clean_port_start for fm0/port/MAC/9
DBG1: Invocation of FM_PCD_NetEnvCharacteristicsDelete for fm0/port/MAC/9 succeeded
DBG1: fmc_exec_engine_start - execution started
DBG1: Invocation of FM_Open from fmc_exec_engine_start for fm0
DBG1: Invocation of FM_Open for fm0 succeeded
DBG1: Invocation of FM_PCD_Open from fmc_exec_engine_start for fm0/pcd
DBG1: Invocation of FM_PCD_Open for fm0/pcd succeeded
DBG1: Invocation of FM_PCD_Enable from fmc_exec_engine_start for fm0/pcd
DBG1: Invocation of FM_PCD_Enable for fm0/pcd succeeded
DBG1: fmc_exec_engine_start - execution ended
DBG1: Invocation of FM_PORT_Open from fmc_exec_port_start for fm0/port/MAC/9
DBG1: Invocation of FM_PORT_Open for fm0/port/MAC/9 succeeded
DBG1: Invocation of FM_PCD_NetEnvCharacteristicsSet from fmc_exec_port_start for fm0/port/MAC/9
DBG1: Invocation of FM_PCD_NetEnvCharacteristicsSet for fm0/port/MAC/9 succeeded
DBG1: Invocation of FM_PCD_KgSchemeSet from fmc_exec_scheme for fm0/port/MAC/9/dist/garbage_dist_9
DBG1: Invocation of FM_PCD_KgSchemeSet for fm0/port/MAC/9/dist/garbage_dist_9 succeeded
DBG1: Invocation of FM_PORT_Disable from fmc_exec_port_end for fm0/port/MAC/9
DBG1: Invocation of FM_PORT_Disable for fm0/port/MAC/9 succeeded
DBG1: Invocation of FM_PORT_SetPCD from fmc_exec_port_end for fm0/port/MAC/9
DBG1: Invocation of FM_PORT_SetPCD for fm0/port/MAC/9 succeeded
DBG1: Invocation of FM_PORT_Enable from fmc_exec_port_end for fm0/port/MAC/9
DBG1: Invocation of FM_PORT_Enable for fm0/port/MAC/9 succeeded
DBG1: Invocation of FM_PORT_Open from fmc_exec_port_start for fm0/port/MAC/10
DBG1: Invocation of FM_PORT_Open for fm0/port/MAC/10 succeeded
DBG1: Invocation of FM_PCD_NetEnvCharacteristicsSet from fmc_exec_port_start for fm0/port/MAC/10
DBG1: Invocation of FM_PCD_NetEnvCharacteristicsSet for fm0/port/MAC/10 succeeded
DBG1: Invocation of FM_PCD_KgSchemeSet from fmc_exec_scheme for fm0/port/MAC/10/dist/garbage_dist_10
DBG1: Invocation of FM_PCD_KgSchemeSet for fm0/port/MAC/10/dist/garbage_dist_10 succeeded
DBG1: Invocation of FM_PORT_Disable from fmc_exec_port_end for fm0/port/MAC/10
DBG1: Invocation of FM_PORT_Disable for fm0/port/MAC/10 succeeded
DBG1: Invocation of FM_PORT_SetPCD from fmc_exec_port_end for fm0/port/MAC/10
DBG1: Invocation of FM_PORT_SetPCD for fm0/port/MAC/10 succeeded
DBG1: Invocation of FM_PORT_Enable from fmc_exec_port_end for fm0/port/MAC/10
DBG1: Invocation of FM_PORT_Enable for fm0/port/MAC/10 succeeded

 

0 Kudos
1 Solution
1,962 Views
yipingwang
NXP TechSupport
NXP TechSupport

There is limitation in Linux Kernel to handle PCD distribution queues as the above method, we could implement this purpose in USDPAA through this PCD configuration.

View solution in original post

0 Kudos
4 Replies
1,014 Views
sergey_gavrish
Contributor II

Hello, by this example i'm trying to forward something from one mac to another, and not understand if kernel crashes, is it possible to forward some any trafic by fman? or another question if NO so for what FMAN stands for if can't do forwarding?

0 Kudos
1,996 Views
yipingwang
NXP TechSupport
NXP TechSupport

Please check whether it could work when configure Rx queue in the PCD policy file.

policy_ipv4.xml

<distribution name="garbage_dist_9">
<queue count="1" base="0x51"/>
</distribution>

<distribution name="garbage_dist_10">
<queue count="1" base="0x50"/>
</distribution>

<policy name="fm_policy_9">
<dist_order>
<distributionref name="garbage_dist_9"/>
</dist_order>
</policy>

<policy name="fm_policy_10">
<dist_order>
<distributionref name="garbage_dist_10"/>
</dist_order>
</policy>

 

In addition, please modify policy file based on /etc/fmc/config/private/ls1046ardb/RR_FFSSPPPH_1133_5559/policy_ipv4.xml.

Please try whether it could work normally when executing 

fmc -c /etc/fmc/config/private/ls1046ardb/RR_FFSSPPPH_1133_5559/config.xml -p /etc/fmc/config/private/ls1046ardb/RR_FFSSPPPH_1133_5559/policy_ipv4.xml -a

0 Kudos
1,989 Views
alance
Contributor II

Hi YiPing

Had tried setting Rx and Tx error queues on PCD. Both work fine and I can check the ifconfig counters. However, kernel crashes when sending a packet to PCD with the Tx queue. Can we set TX FQID on the PCD distribution queue? Or any settings we need to set beforehand?

0 Kudos
1,963 Views
yipingwang
NXP TechSupport
NXP TechSupport

There is limitation in Linux Kernel to handle PCD distribution queues as the above method, we could implement this purpose in USDPAA through this PCD configuration.

0 Kudos