lkml.org 
[lkml]   [2004]   [Aug]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH 4/5] netpoll: increase NAPI budget
From: Jeff Moyer <jmoyer@redhat.com>

Hi, Matt,

I've upped the poll budget to 16 and added a comment explaining why. I
definitely ran into this problem when testing netdump.

Signed-off-by: Jeff Moyer <jmoyer@redhat.com>
Signed-off-by: Matt Mackall <mpm@selenic.com>

--- linux-2.6.7/net/core/netpoll.c.budget 2004-08-16 12:33:10.176533688 -0400
+++ linux-2.6.7/net/core/netpoll.c 2004-08-16 12:37:15.510237296 -0400
@@ -61,7 +61,13 @@ static int checksum_udp(struct sk_buff *

void netpoll_poll(struct netpoll *np)
{
- int budget = 1;
+ /*
+ * In cases where there is bi-directional communications, reading
+ * only one message at a time can lead to packets being dropped by
+ * the network adapter, forcing superfluous retries and possibly
+ * timeouts. Thus, we set our budget to a more reasonable value.
+ */
+ int budget = 16;

if(!np->dev || !netif_running(np->dev) || !np->dev->poll_controller)
return;

--
Mathematics is the supreme nostalgia of our time.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:05    [W:0.022 / U:0.836 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site