[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1371829145.3570.46.camel@bwh-desktop.uk.level5networks.com>
Date: Fri, 21 Jun 2013 16:39:05 +0100
From: Ben Hutchings <bhutchings@...arflare.com>
To: "Nelson, Shannon" <shannon.nelson@...el.com>
CC: "Kirsher, Jeffrey T" <jeffrey.t.kirsher@...el.com>,
"davem@...emloft.net" <davem@...emloft.net>,
"Brandeburg, Jesse" <jesse.brandeburg@...el.com>,
"netdev@...r.kernel.org" <netdev@...r.kernel.org>,
"gospo@...hat.com" <gospo@...hat.com>,
"sassmann@...hat.com" <sassmann@...hat.com>,
"Waskiewicz Jr, Peter P" <peter.p.waskiewicz.jr@...el.com>,
"e1000-devel@...ts.sourceforge.net"
<e1000-devel@...ts.sourceforge.net>
Subject: Structured ethtool statistic names
On Thu, 2013-06-20 at 20:04 +0000, Nelson, Shannon wrote:
> > From: Ben Hutchings [mailto:bhutchings@...arflare.com]
> > Sent: Thursday, June 20, 2013 12:59 PM
> >
> > On Thu, 2013-06-20 at 19:47 +0000, Nelson, Shannon wrote:
[...]
> > > When ethtool -S is called on the PF's netdev, we see both the netdev
> > > and the ports stats printed. When called on non-PF connection we only
> > > see the netdev stats, none of the port stats.
> >
> > Good point. And this is something I've been meaning to bring up for
> > discussion on netdev myself - we should have some naming convention to
> > distinguish per-port and per-function/per-netdev statistics.
>
> If you've got some ideas on a convention to use, we'd be happy to set the precedent.
OK, how about:
1. Statistic names are made up of "." separators and name components
that do not include "." or whitespace.
2. Names of statistics for the net device as a whole have a single name
component.
3. Names of statistics for the external port, where there is a useful
distinction from the net device, follow the format:
"port." name-component.
Rationale: Only virtualised NIC drivers require a distinction, so the
convention should allow other drivers to comply without changes.
Statistics are requested on a specific net device, so that device's own
statistics should be considered primary and not given a prefix.
Since other people have been adding or proposing to add them:
4. Names of statistics for a single queue follow the format:
queue-type "-" index "." name-component
Where queue-type is "rx" or "tx" and index is the index of the queue as
used in the kernel.
Rationale: This queue naming is consistent with the queue objects in
sysfs.
This should be extensible to allow for reading, say, VF statistics
through a PF net device, e.g. "vf-" index "." name-component.
Ben.
--
Ben Hutchings, Staff Engineer, Solarflare
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists