[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20071220.035621.147230372.davem@davemloft.net>
Date: Thu, 20 Dec 2007 03:56:21 -0800 (PST)
From: David Miller <davem@...emloft.net>
To: ilpo.jarvinen@...sinki.fi
Cc: netdev@...r.kernel.org, herbert@...dor.apana.org.au,
jheffner@....edu
Subject: Re: TSO trimming question
From: "Ilpo_Järvinen" <ilpo.jarvinen@...sinki.fi>
Date: Thu, 20 Dec 2007 13:40:51 +0200 (EET)
> [PATCH] [TCP]: Fix TSO deferring
>
> I'd say that most of what tcp_tso_should_defer had in between
> there was dead code because of this.
>
> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@...sinki.fi>
Yikes!!!!!
John, we've been living a lie for more than a year. :-/
On the bright side this explains a lot of small TSO frames I've been
seeing in traces over the past year but never got a chance to
investigate.
> diff --git a/net/ipv4/tcp_output.c b/net/ipv4/tcp_output.c
> index 8dafda9..693b9f6 100644
> --- a/net/ipv4/tcp_output.c
> +++ b/net/ipv4/tcp_output.c
> @@ -1217,7 +1217,8 @@ static int tcp_tso_should_defer(struct sock *sk, struct sk_buff *skb)
> goto send_now;
>
> /* Defer for less than two clock ticks. */
> - if (!tp->tso_deferred && ((jiffies<<1)>>1) - (tp->tso_deferred>>1) > 1)
> + if (tp->tso_deferred &&
> + ((jiffies << 1) >> 1) - (tp->tso_deferred >> 1) > 1)
> goto send_now;
>
> in_flight = tcp_packets_in_flight(tp);
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists