Author: tuexen Date: Tue Aug 25 09:42:03 2020 New Revision: 364754 URL: https://svnweb.freebsd.org/changeset/base/364754
Log: RFC 3465 defines a limit L used in TCP slow start for limiting the number of acked bytes as described in Section 2.2 of that document. This patch ensures that this limit is not also applied in congestion avoidance. Applying this limit also in congestion avoidance can result in using less bandwidth than allowed. Reported by: l.tian.em...@gmail.com Reviewed by: rrs, rscheff MFC after: 3 days Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D26120 Modified: head/sys/netinet/tcp_input.c head/sys/netinet/tcp_stacks/rack.c Modified: head/sys/netinet/tcp_input.c ============================================================================== --- head/sys/netinet/tcp_input.c Tue Aug 25 06:49:10 2020 (r364753) +++ head/sys/netinet/tcp_input.c Tue Aug 25 09:42:03 2020 (r364754) @@ -349,8 +349,7 @@ cc_ack_received(struct tcpcb *tp, struct tcphdr *th, u } #endif /* STATS */ if (tp->snd_cwnd > tp->snd_ssthresh) { - tp->t_bytes_acked += min(tp->ccv->bytes_this_ack, - nsegs * V_tcp_abc_l_var * tcp_maxseg(tp)); + tp->t_bytes_acked += tp->ccv->bytes_this_ack; if (tp->t_bytes_acked >= tp->snd_cwnd) { tp->t_bytes_acked -= tp->snd_cwnd; tp->ccv->flags |= CCF_ABC_SENTAWND; Modified: head/sys/netinet/tcp_stacks/rack.c ============================================================================== --- head/sys/netinet/tcp_stacks/rack.c Tue Aug 25 06:49:10 2020 (r364753) +++ head/sys/netinet/tcp_stacks/rack.c Tue Aug 25 09:42:03 2020 (r364754) @@ -3911,8 +3911,7 @@ rack_ack_received(struct tcpcb *tp, struct tcp_rack *r #endif } if (rack->r_ctl.cwnd_to_use > tp->snd_ssthresh) { - tp->t_bytes_acked += min(tp->ccv->bytes_this_ack, - nsegs * V_tcp_abc_l_var * ctf_fixed_maxseg(tp)); + tp->t_bytes_acked += tp->ccv->bytes_this_ack; if (tp->t_bytes_acked >= rack->r_ctl.cwnd_to_use) { tp->t_bytes_acked -= rack->r_ctl.cwnd_to_use; tp->ccv->flags |= CCF_ABC_SENTAWND; _______________________________________________ svn-src-all@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"