From: Jarek Poplawski <jarkao2@gmail.com>
To: =?UTF-8?B?SmFrdWIgUnXFvmnEjWth?= <ruzicka.jakub@gmail.com>
Cc: netdev@vger.kernel.org
Subject: Re: via-rhine interrupts
Date: Sun, 15 Aug 2010 22:04:31 +0200 [thread overview]
Message-ID: <20100815200431.GA4993@del.dom.local> (raw)
In-Reply-To: <AANLkTi=xfBSn=FS9=eR=NZa9QwrHAQwGc7Kh1-bUn3aj@mail.gmail.com>
Jakub RuĹžiÄka wrote, On 29.07.2010 13:03:
> Hello,
Hi,
> the via-rhine driver powered cards generate a really big number of
> interrupts, almost one per packet (11429 interrupts for 8210 incoming
> and 2475 outgoing packets per second on full 100 Mbps load). This is
> observed on multiple different machines (embbed and desktop) and
> kernels (2.6.25 with and without NAPI, 2.6.30, 2.6.32 and 2.6.33). Do
> you have any idea why isn't the polling used or what can I try to find
> out what's wrong?
>
> I have tested sending to/from the machines with nc and scp, measured
> interrups and load with atop. Few of these measurements on an embbed
> device (where the interrupt handling is a problem) are attached.
I've just tested it using a simplistic patch below, which skips
some napi receiving by doing it only every second jiffie (on even
ones), and I've got around 30% less interrupts from via-rhine,
which seems to suggest napi works OK, but there is too low
traffic (or too fast soft interrupt handling) to affect hard
interrupts. (Btw, probably CONFIG_HZ can matter here a bit too.
I tested with 1000.)
Cheers,
Jarek P.
--- (patch only for testing)
diff -Nurp a/net/core/dev.c b/net/core/dev.c
--- a/net/core/dev.c 2010-08-15 20:29:58.000000000 +0200
+++ b/net/core/dev.c 2010-08-15 21:15:04.000000000 +0200
@@ -3495,6 +3495,9 @@ static void net_rx_action(struct softirq
if (unlikely(budget <= 0 || time_after(jiffies, time_limit)))
goto softnet_break;
+ if (jiffies & 1)
+ goto softnet_break;
+
local_irq_enable();
/* Even though interrupts have been re-enabled, this
next prev parent reply other threads:[~2010-08-15 20:04 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-29 11:03 via-rhine interrupts Jakub Ružička
2010-08-15 20:04 ` Jarek Poplawski [this message]
2010-08-19 6:49 ` David Miller
2010-08-19 17:09 ` Jarek Poplawski
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=20100815200431.GA4993@del.dom.local \
--to=jarkao2@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=ruzicka.jakub@gmail.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;
as well as URLs for NNTP newsgroup(s).