Skip to content

Commit

Permalink
dpaa2-eth: trim debugfs FQ stats
Browse files Browse the repository at this point in the history
With the addition of multiple traffic classes support, the number
of available frame queues grew significantly, overly inflating the
debugfs FQ statistics entry. Update it to only show the queues
which are actually in use (i.e. have a non-zero frame counter).

Signed-off-by: Ioana Radulescu <ruxandra.radulescu@nxp.com>
Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Ioana Radulescu authored and David S. Miller committed Jun 25, 2020
1 parent 575691b commit 0da1e28
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions drivers/net/ethernet/freescale/dpaa2/dpaa2-eth-debugfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,10 @@ static int dpaa2_dbg_fqs_show(struct seq_file *file, void *offset)
if (err)
fcnt = 0;

/* Skip FQs with no traffic */
if (!fq->stats.frames && !fcnt)
continue;

seq_printf(file, "%5d%16d%16d%16s%16llu%16u\n",
fq->fqid,
fq->target_cpu,
Expand Down

0 comments on commit 0da1e28

Please sign in to comment.