Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 13 Jul 2012 10:54:35 -0700
From:      Reese Faucette <reese@myri.com>
To:        freebsd-net@freebsd.org
Subject:   question in tcp_do_segment()
Message-ID:  <500060DB.3090407@myri.com>
In-Reply-To: <4FFF9E48.6000403@myri.com>
References:  <4FFF9E48.6000403@myri.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi, freebsd-net-

I don't have a testcase for this at the moment, but there's a test
in tcp_do_segment that looks backwards to me...

http://svnweb.freebsd.org/base/release/9.0.0/sys/netinet/tcp_input.c?view=markup

line 2398 -
	if (!tcp_timer_active(tp, TT_REXMT) ||
             th->th_ack != tp->snd_una)
                tp->t_dupacks = 0;

says "If we get a DUP ack and the retransmit timer is NOT
fired, then ignore it and reset DUP ACK count."

Isn't that exactly backwards?  I could see ignoring the DUP ACK if we
know the retransmit timer HAS fired, and we don't want to interfere with
its retransmission efforts.  The way the code is written now, as far as
I can see, completely defeats retransmission based on DUP acks.  I
accidentally ran across this by breaking the timer, so that the
retransmit timer never fires, and my streams get stuck, even with plenty 
of DUP ACKs.

Am I missing something, or should that "!" go ?

Thanks,
Reese Faucette
Myricom, Inc.





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?500060DB.3090407>