Thread (41 messages) 41 messages, 6 authors, 2012-10-08

Re: [PATCH] net: gro: selective flush of packets

From: Herbert Xu <herbert@gondor.apana.org.au>
Date: 2012-10-07 00:32:16

On Sat, Oct 06, 2012 at 08:08:49PM +0200, Eric Dumazet wrote:
quoted hunk ↗ jump to hunk
@@ -3981,8 +3996,17 @@ static void net_rx_action(struct softirq_action *h)
 				local_irq_enable();
 				napi_complete(n);
 				local_irq_disable();
-			} else
+			} else {
+				if (n->gro_list) {
+					/* flush too old packets
+					 * If HZ < 1000, flush all packets.
+					 */
+					local_irq_enable();
+					napi_gro_flush(n, HZ >= 1000);
+					local_irq_disable();
+				}
 				list_move_tail(&n->poll_list, &sd->poll_list);
+			}
Why don't we just always flush everything?

Thanks,
-- 
Email: Herbert Xu [off-list ref]
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help