buff += ETH_GSTRING_LEN;
if (node < DSAF_SERVICE_NW_NUM && !is_ver1) {
for (i = 0; i < DSAF_PRIO_NR; i++) {
- snprintf(buff, ETH_GSTRING_LEN,
- "inod%d_pfc_prio%d_pkts", node, i);
- buff += ETH_GSTRING_LEN;
- }
- for (i = 0; i < DSAF_PRIO_NR; i++) {
- snprintf(buff, ETH_GSTRING_LEN,
- "onod%d_pfc_prio%d_pkts", node, i);
+ snprintf(buff + 0 * ETH_GSTRING_LEN * DSAF_PRIO_NR,
+ ETH_GSTRING_LEN, "inod%d_pfc_prio%d_pkts",
+ node, i);
+ snprintf(buff + 1 * ETH_GSTRING_LEN * DSAF_PRIO_NR,
+ ETH_GSTRING_LEN, "onod%d_pfc_prio%d_pkts",
+ node, i);
buff += ETH_GSTRING_LEN;
}
+ buff += 1 * DSAF_PRIO_NR * ETH_GSTRING_LEN;
}
snprintf(buff, ETH_GSTRING_LEN, "onnod%d_tx_pkts", node);
buff += ETH_GSTRING_LEN;
p[12] = hw_stats->stp_drop;
if (node_num < DSAF_SERVICE_NW_NUM && !is_ver1) {
for (i = 0; i < DSAF_PRIO_NR; i++) {
- p[13 + i] = hw_stats->rx_pfc[i];
- p[13 + i + DSAF_PRIO_NR] = hw_stats->tx_pfc[i];
+ p[13 + i + 0 * DSAF_PRIO_NR] = hw_stats->rx_pfc[i];
+ p[13 + i + 1 * DSAF_PRIO_NR] = hw_stats->tx_pfc[i];
}
p[29] = hw_stats->tx_pkts;
return &p[30];