net: reduce net_rx_action() latency to 2 HZ
authorEric Dumazet <edumazt@google.com>
Tue, 5 Mar 2013 07:15:13 +0000 (07:15 +0000)
committerDavid S. Miller <davem@davemloft.net>
Wed, 6 Mar 2013 07:47:06 +0000 (02:47 -0500)
We should use time_after_eq() to get maximum latency of two ticks,
instead of three.

Bug added in commit 24f8b2385 (net: increase receive packet quantum)

Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/core/dev.c

index 5ca8734..8f152f9 100644 (file)
@@ -4103,7 +4103,7 @@ static void net_rx_action(struct softirq_action *h)
                 * Allow this to run for 2 jiffies since which will allow
                 * an average latency of 1.5/HZ.
                 */
-               if (unlikely(budget <= 0 || time_after(jiffies, time_limit)))
+               if (unlikely(budget <= 0 || time_after_eq(jiffies, time_limit)))
                        goto softnet_break;
 
                local_irq_enable();