svn commit: r211874 - head/sys/netinet
Andre Oppermann
andre at FreeBSD.org
Fri Aug 27 12:34:53 UTC 2010
Author: andre
Date: Fri Aug 27 12:34:53 2010
New Revision: 211874
URL: http://svn.freebsd.org/changeset/base/211874
Log:
Use timestamp modulo comparison macro for automatic receive buffer
scaling to correctly handle wrapping of ticks value.
MFC after: 1 week
Modified:
head/sys/netinet/tcp_input.c
Modified: head/sys/netinet/tcp_input.c
==============================================================================
--- head/sys/netinet/tcp_input.c Fri Aug 27 11:08:11 2010 (r211873)
+++ head/sys/netinet/tcp_input.c Fri Aug 27 12:34:53 2010 (r211874)
@@ -1441,7 +1441,7 @@ tcp_do_segment(struct mbuf *m, struct tc
if (V_tcp_do_autorcvbuf &&
to.to_tsecr &&
(so->so_rcv.sb_flags & SB_AUTOSIZE)) {
- if (to.to_tsecr > tp->rfbuf_ts &&
+ if (TSTMP_GT(to.to_tsecr, tp->rfbuf_ts) &&
to.to_tsecr - tp->rfbuf_ts < hz) {
if (tp->rfbuf_cnt >
(so->so_rcv.sb_hiwat / 8 * 7) &&
More information about the svn-src-head
mailing list