From: Jeff Sipek <jeffpc@optonline.net>
To: Jeff Garzik <jgarzik@pobox.com>
Cc: Kernel Mailing List <linux-kernel@vger.kernel.org>,
Andrew Morton <akpm@digeo.com>,
Dave Jones <davej@codemonkey.org.uk>,
Linus Torvalds <torvalds@osdl.org>,
netdev@oss.sgi.com
Subject: Re: [PATCH - RFC] [1/5] 64-bit network statistics - generic net
Date: Fri, 04 Jul 2003 02:02:03 -0400 [thread overview]
Message-ID: <200307040200.08574.jeffpc@optonline.net> (raw)
In-Reply-To: <3F04EAA0.2050102@pobox.com>
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Thursday 03 July 2003 22:46, Jeff Garzik wrote:
> Jeff Sipek wrote:
> > + spinlock_t rx_packets;
<snip>
> > + spinlock_t tx_compressed;
>
> That's a fat daddy list of locks you got there.
Yeah, I know, I am sure there is a way of getting rid of some of those.. (i.e.
the tx functions are inside a spinlock from struct net_device.)
> > + NETSTAT_TYPE _rx_packets; /* total packets received */
> > + NETSTAT_TYPE _tx_packets; /* total packets transmitted */
> > + NETSTAT_TYPE _rx_bytes; /* total bytes received */
> > + NETSTAT_TYPE _tx_bytes; /* total bytes transmitted */
> > + NETSTAT_TYPE _rx_errors; /* bad packets received */
> > + NETSTAT_TYPE _tx_errors; /* packet transmit problems */
> > + NETSTAT_TYPE _rx_dropped; /* no space in linux buffers */
> > + NETSTAT_TYPE _tx_dropped; /* no space available in linux */
> > + NETSTAT_TYPE _multicast; /* multicast packets received */
> > + NETSTAT_TYPE _collisions;
>
> Increasing user-visible sizes arbitrarily breaks stuff. Having
> config-dependent types like this increases complexity.
Not really, those macros used to change the variables hide everything from the
driver programmer. Besides those changes in procfs and sysfs which always
return 64-bits, everything else is type casted (if needed) by those macros -
depending on CONFIG_NETSTATS64.
> Short term, just sample the stats more rapidly.
That's what Linus said. But it is only a temporary fix.
> Long term, I suppose with 10GbE we should start thinking about this.
> Personally, I would prefer to make the standard net device stats
> available in the format already exported by ETHTOOL_GSTATS -- which I
> note uses u64's for its counters, and it's easily extensible. I
> received a request for this just today, even.
I was thinking about making the 64-bit stats mandatory, but then I opted to
make in an option in the config. (As Linus pointed out, some people want
performance, not statistics.)
Jeff.
- --
I'm somewhere between geek and normal.
- Linus Torvalds
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)
iD8DBQE/BRhfwFP0+seVj/4RAtBbAJ4nmbs8ZQLgFagfb4KrJGZ55AYTmwCgzkcs
1uPma124BorLUdrcsbF2Txs=
=EIag
-----END PGP SIGNATURE-----
next prev parent reply other threads:[~2003-07-04 6:02 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <200307032231.39842.jeffpc@optonline.net>
2003-07-04 2:46 ` [PATCH - RFC] [1/5] 64-bit network statistics - generic net Jeff Garzik
2003-07-04 6:02 ` Jeff Sipek [this message]
[not found] ` <20030704094745.GG29233@lug-owl.de>
2003-07-04 17:57 ` Jeff Sipek
[not found] <Pine.LNX.4.44.0307032005340.8468-100000@home.osdl.org>
2003-07-04 5:27 ` Jeff Sipek
2003-07-05 18:49 ` Jeff Sipek
2003-07-05 21:46 ` Ben Greear
[not found] <E19YtAq-0006Xf-00@calista.inka.de>
2003-07-05 20:37 ` Jeff Sipek
2003-07-05 20:40 ` Jeff Garzik
2003-07-05 20:59 ` Jeff Sipek
2003-07-05 21:51 ` Francois Romieu
2003-07-05 22:39 ` Jeff Sipek
2003-07-05 23:44 ` Francois Romieu
2003-07-05 22:54 ` Roland Dreier
2003-07-05 21:41 ` Ben Greear
2003-07-06 7:27 ` Alan Cox
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200307040200.08574.jeffpc@optonline.net \
--to=jeffpc@optonline.net \
--cc=akpm@digeo.com \
--cc=davej@codemonkey.org.uk \
--cc=jgarzik@pobox.com \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@oss.sgi.com \
--cc=torvalds@osdl.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).