net: atlantic: per-TC queue statistics
authorMark Starovoytov <mstarovoitov@marvell.com>
Fri, 22 May 2020 08:19:41 +0000 (11:19 +0300)
committerDavid S. Miller <davem@davemloft.net>
Fri, 22 May 2020 21:08:28 +0000 (14:08 -0700)
commit4272ba8b11f88be8daca5e2477bfe110145d559c
tree53bc1087452e1e7614d80e2ec488ada44d397402
parenta83fe6b6ad6b10f6912025ae23bd5c2596a4e7f4
net: atlantic: per-TC queue statistics

This patch adds support for per-TC queue statistics.

By default (single TC), the output is the same as it used to be, e.g.:
     Queue[0] InPackets: 2
     Queue[0] OutPackets: 8
     Queue[0] Restarts: 0
     Queue[0] InJumboPackets: 0
     Queue[0] InLroPackets: 0
     Queue[0] InErrors: 0

If several TCs are enabled, then each queue statistics line is prefixed
with TC number, e.g.:
     TC0 Queue[0] InPackets: 6
     TC0 Queue[0] OutPackets: 11
Queue numbering is end-to-end, so:
     TC1 Queue[4] InPackets: 0
     TC1 Queue[4] OutPackets: 22

Signed-off-by: Mark Starovoytov <mstarovoitov@marvell.com>
Signed-off-by: Igor Russkikh <irusskikh@marvell.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/aquantia/atlantic/aq_ethtool.c
drivers/net/ethernet/aquantia/atlantic/aq_nic.c
drivers/net/ethernet/aquantia/atlantic/aq_vec.c
drivers/net/ethernet/aquantia/atlantic/aq_vec.h