Subject: Re: [PATCH] tcp: Fix for stalling connections

From: Eric Dumazet <[email-masked]>
Date: Mon, 07 Dec 2009 07:15:48 +0100

Damian Lukowski a écrit :
> This patch fixes a problem in the TCP connection timeout calculation.
> Currently, timeout decisions are made on the basis of the current
> tcp_time_stamp and retrans_stamp, which is usually set at the first
> retransmission.
> However, if the retransmission fails in tcp_retransmit_skb(),
> retrans_stamp is not updated and remains zero. This leads to wrong
> decisions in retransmits_timed_out() if tcp_time_stamp is larger than
> the specified timeout, which is very likely.
> In this case, the TCP connection dies after the first attempted
> (and unsuccessful) retransmission.
> 
> With this patch, tcp_skb_cb->when is used instead, when retrans_stamp
> is not available.
> 
> Thanks to Ilpo Järvinen for code suggestions.
> 
> Signed-off-by: Damian Lukowski <[email-masked]>

Hmm, how old is this bug ?

You should a hint of faulty commit so that stable team can apply
this patch to 2.6.32 & 2.6.31

git describe 6fa12c85031485dff38ce550c24f10da23b0adaa

v2.6.31-rc5-1853-g6fa12c8

Or maybe David handles this for us, I dont know...

Minor note : retransmits_timed_out() is used in from net/ipv4/tcp_timer.c
I wonder why its a "static inline" in include/net/tcp.h

Thanks