Date: Mon, 06 Jun 2005 15:20:13 +0900 (JST) From: Noritoshi Demizu <demizu@dd.iij4u.or.jp> To: Jiawei Ye <leafy7382@gmail.com> Cc: freebsd-current@freebsd.org Subject: Re: Is this the sign of a problem? Message-ID: <20050606.152013.55717574.Noritoshi@Demizu.ORG> In-Reply-To: <c21e92e205060523075109cc41@mail.gmail.com> References: <c21e92e205060523075109cc41@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
> The following message repeats quite often in /var/log/messages > kernel: tcp_sack_output: Computed sack_bytes_retransmitted (2636) not > the same as cached value (5307) > > Is this a sign of problems? Yes. Thanks for your report. The patch below would fix the problem. It will be committed soon. Regards, Noritoshi Demizu Index: tcp_sack.c =================================================================== RCS file: /home/cvsup/FreeBSD/ncvs/src/sys/netinet/tcp_sack.c,v retrieving revision 1.21 diff -u -r1.21 tcp_sack.c --- tcp_sack.c 4 Jun 2005 08:03:28 -0000 1.21 +++ tcp_sack.c 6 Jun 2005 03:21:26 -0000 @@ -508,8 +508,6 @@ cur->start = sblkp->end; cur->rxmit = SEQ_MAX(cur->rxmit, cur->start); } - /* Go to the previous hole. */ - cur = TAILQ_PREV(cur, sackhole_head, scblink); } else { /* Data acks at least the end of hole */ if (SEQ_GEQ(sblkp->end, cur->end)) { @@ -535,10 +533,17 @@ cur->end); } } - /* Go to the previous sack block. */ - sblkp--; } tp->sackhint.sack_bytes_rexmit += (cur->rxmit - cur->start); + /* + * Testing sblkp->start against cur->start tells us whether + * we're done with the sack block or the sack hole. + * Accordingly, we advance one or the other. + */ + if (SEQ_LEQ(sblkp->start, cur->start)) + cur = TAILQ_PREV(cur, sackhole_head, scblink); + else + sblkp--; } return (0); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050606.152013.55717574.Noritoshi>