blob: 1327b37e6451ac7a3fb0390312bc7d621f376100 [file] [log] [blame]
b.liue9582032025-04-17 19:18:16 +08001From 2b19aa3f602c9d9d71959c6306c385927fb9578c Mon Sep 17 00:00:00 2001
2From: Ioana Radulescu <ruxandra.radulescu@nxp.com>
3Date: Tue, 17 Sep 2019 16:53:03 +0300
4Subject: [PATCH] dpaa2-eth: Trim debugfs FQ stats
5
6With the addition of multiple traffic classes support, the number
7of available frame queues grew significantly, overly inflating the
8debugfs FQ statistics entry. Update it to only show the queues
9which are actually in use (i.e. have a non-zero frame counter).
10
11Signed-off-by: Ioana Radulescu <ruxandra.radulescu@nxp.com>
12---
13 drivers/net/ethernet/freescale/dpaa2/dpaa2-eth-debugfs.c | 4 ++++
14 1 file changed, 4 insertions(+)
15
16--- a/drivers/net/ethernet/freescale/dpaa2/dpaa2-eth-debugfs.c
17+++ b/drivers/net/ethernet/freescale/dpaa2/dpaa2-eth-debugfs.c
18@@ -90,6 +90,10 @@ static int dpaa2_dbg_fqs_show(struct seq
19 if (err)
20 fcnt = 0;
21
22+ /* Skip FQs with no traffic */
23+ if (!fq->stats.frames && !fcnt)
24+ continue;
25+
26 seq_printf(file, "%5d%16d%16d%16s%16llu%16u\n",
27 fq->fqid,
28 fq->target_cpu,