public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Jesper Dangaard Brouer <hawk@diku.dk>
To: David Miller <davem@davemloft.net>
Cc: jeffrey.t.kirsher@intel.com, hawk@comx.dk,
	netdev <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: Re: [PATCH] igb: Record hardware RX overruns in net_stats
Date: Tue, 5 May 2009 23:24:31 +0200 (CEST)	[thread overview]
Message-ID: <Pine.LNX.4.64.0905052249110.1294@ask.diku.dk> (raw)
In-Reply-To: <20090505.115819.84151021.davem@davemloft.net>

On Tue, 5 May 2009, David Miller wrote:

> From: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
> Date: Tue, 5 May 2009 11:47:09 -0700
>
>> NAK.  RNBC is not a counter for buffer overruns, and so should not be
>> counted as such.
>
> I'd say technically it is, it indicates that more packets arrived than
> the available receive buffers could handle.

I agree with DaveM. Technically it _is_ a buffer overflow, but in the host 
memory not the NIC. I'm sort of pushing the system into a situation where 
it cannot empty the receive buffers fast enough.

I can fairly easily provoke this situation by adding too many iptables 
rules, which (intentionally) cause high CPU load and causes ksoftirqd to 
run (I'm Oprofiling netfilter modules).


> If anything, this is the closest this device has for this kind of
> situation, and it's useful for diagnosing problems.

Its really useful for diagnosing problems, and I'm betting that this is a 
real-life situation which people is going to experience. We might as well 
help our self to more easily identify this issue when people report drop 
problems.

Notice that I'm seeing:

   rx_no_buffer_count: 136955
   rx_missed_errors: 0

Thus, the rx_missed_errors is zero, which according to the datasheet is 
the "real" fifo drop (the MPC register, Missed Packets Count) and PCI 
bandwidth problem indications.

If we really should nitpick, then:

  adapter->net_stats.rx_missed_errors = adapter->stats.mpc

Should then have been stored in the rx_fifo_errors.  Notice that 
rx_missed_errors is presented to userspace as drops (see 
net/core/dev.c:2624).

I think that both MPC and RNBC should be stored in rx_fifo_errors (and of 
cause still keeping them seperate to ethtool -S).

I'll post two patches with these changes tomorrow, for you evaluation.

Please reconsider you NAK.

Greetings,
   Jesper Brouer

--
-------------------------------------------------------------------
MSc. Master of Computer Science
Dept. of Computer Science, University of Copenhagen
Author of http://www.adsl-optimizer.dk
-------------------------------------------------------------------

  reply	other threads:[~2009-05-05 21:24 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-04 11:06 [PATCH] igb: Record hardware RX overruns in net_stats Jesper Dangaard Brouer
2009-05-05 18:47 ` Jeff Kirsher
2009-05-05 18:58   ` David Miller
2009-05-05 21:24     ` Jesper Dangaard Brouer [this message]
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=Pine.LNX.4.64.0905052249110.1294@ask.diku.dk \
    --to=hawk@diku.dk \
    --cc=bruce.w.allan@intel.com \
    --cc=davem@davemloft.net \
    --cc=e1000-devel@lists.sourceforge.net \
    --cc=hawk@comx.dk \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox