All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jesper Dangaard Brouer <hawk@comx.dk>
To: "David S. Miller" <davem@davemloft.net>, jeffrey.t.kirsher@intel.com
Cc: "netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	e1000-devel@lists.sourceforge.net, jesse.brandeburg@intel.com,
	bruce.w.allan@intel.com, peter.p.waskiewicz.jr@intel.com,
	john.ronciak@intel.com
Subject: [PATCH] igb: Record hardware RX overruns in net_stats
Date: Mon, 04 May 2009 13:06:46 +0200	[thread overview]
Message-ID: <1241435206.8115.104.camel@localhost.localdomain> (raw)


Hardware RX fifo overruns for the 82576 is stored in the
RNBC (Receive No Buffers Count) register.

I choose the store the RNBC value in net_stats.rx_fifo_errors.

Saving the stats in dev->net_stats makes it visible via
/proc/net/dev as "fifo", and thus viewable to ifconfig
as "overruns" and 'netstat -i' as "RX-OVR".

The Receive No Buffers Count (RNBC) can already be queried by
ethtool -S as "rx_no_buffer_count".

Signed-off-by: Jesper Dangaard Brouer <hawk@comx.dk>
---

 drivers/net/igb/igb_main.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)


diff --git a/drivers/net/igb/igb_main.c b/drivers/net/igb/igb_main.c
index 183235d..ef26e6a 100644
--- a/drivers/net/igb/igb_main.c
+++ b/drivers/net/igb/igb_main.c
@@ -3596,6 +3596,7 @@ void igb_update_stats(struct igb_adapter *adapter)
 	adapter->net_stats.rx_crc_errors = adapter->stats.crcerrs;
 	adapter->net_stats.rx_frame_errors = adapter->stats.algnerrc;
 	adapter->net_stats.rx_missed_errors = adapter->stats.mpc;
+	adapter->net_stats.rx_fifo_errors = adapter->stats.rnbc;
 
 	/* Tx Errors */
 	adapter->net_stats.tx_errors = adapter->stats.ecol +



             reply	other threads:[~2009-05-04 11:06 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-04 11:06 Jesper Dangaard Brouer [this message]
2009-05-05 18:47 ` [PATCH] igb: Record hardware RX overruns in net_stats Jeff Kirsher
2009-05-05 18:58   ` David Miller
2009-05-05 21:24     ` Jesper Dangaard Brouer
2009-05-05 21:32       ` Jeff Kirsher
2009-05-05 21:35         ` David Miller
2009-05-06  7:46           ` Jesper Dangaard Brouer
2009-05-06  8:11             ` Waskiewicz Jr, Peter P
2009-05-06 13:09               ` Jesper Dangaard Brouer
2009-05-06 20:59                 ` Jesper Dangaard Brouer
2009-05-06 21:24                   ` Waskiewicz Jr, Peter P
2009-05-05 22:38       ` Ronciak, John
2009-05-06  8:12         ` Jesper Dangaard Brouer
2009-05-06  8:56           ` [PATCH v2] igb: Record host memory receive overflow " Jesper Dangaard Brouer

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=1241435206.8115.104.camel@localhost.localdomain \
    --to=hawk@comx.dk \
    --cc=bruce.w.allan@intel.com \
    --cc=davem@davemloft.net \
    --cc=e1000-devel@lists.sourceforge.net \
    --cc=jeffrey.t.kirsher@intel.com \
    --cc=jesse.brandeburg@intel.com \
    --cc=john.ronciak@intel.com \
    --cc=netdev@vger.kernel.org \
    --cc=peter.p.waskiewicz.jr@intel.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.