lkml.org 
[lkml]   [2020]   [Nov]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v1 net-next] net: dsa: qca: ar9331: add ethtool stats support
On Mon, Nov 16, 2020 at 01:34:53PM -0800, Jakub Kicinski wrote:
> You must expose relevant statistics via the normal get_stats64 NDO
> before you start dumping free form stuff in ethtool -S.

Completely agree on the point, Jakub, but to be honest we don't give him
that possibility within the DSA framework today, see .ndo_get_stats64 in
net/dsa/slave.c which returns the generic dev_get_tstats64 implementation,
and not something that hooks into the hardware counters, or into the
driver at all, for that matter.

But it's good that you raise the point, I was thinking too that we
should do better in terms of keeping the software counters in sync with
the hardware. But what would be a good reference for keeping statistics
on an offloaded interface? Is it ok to just populate the netdev counters
based on the hardware statistics? And what about the statistics gathered
today in software, could we return them maybe via something like ifstat
--extended=cpu_hits?

\
 
 \ /
  Last update: 2020-11-16 23:25    [W:0.065 / U:3.476 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site