Index: sys/netinet/cc/cc_newreno.c =================================================================== --- sys/netinet/cc/cc_newreno.c +++ sys/netinet/cc/cc_newreno.c @@ -134,7 +134,7 @@ if (type == CC_ACK && !IN_RECOVERY(CCV(ccv, t_flags)) && (ccv->flags & CCF_CWND_LIMITED)) { u_int cw = CCV(ccv, snd_cwnd); - u_int incr = CCV(ccv, t_maxseg); + u_int incr = 0; /* * Regular in-order ACK, open the congestion window. @@ -169,7 +169,7 @@ ccv->flags &= ~CCF_ABC_SENTAWND; else incr = 0; - } else + } else if (ccv->bytes_this_ack > 0) incr = max((incr * incr / cw), 1); } else if (V_tcp_do_rfc3465) { /* @@ -188,7 +188,8 @@ CCV(ccv, t_maxseg)); else incr = min(ccv->bytes_this_ack, CCV(ccv, t_maxseg)); - } + } else if (ccv->bytes_this_ack > 0) + incr = CCV(ccv, t_maxseg); /* ABC is on by default, so incr equals 0 frequently. */ if (incr > 0) CCV(ccv, snd_cwnd) = min(cw + incr, Index: sys/netinet/tcp_input.c =================================================================== --- sys/netinet/tcp_input.c +++ sys/netinet/tcp_input.c @@ -2031,6 +2031,9 @@ TCP_PROBE5(connect__established, NULL, tp, m, tp, th); cc_conn_init(tp); + if ((tlen == 0) && + (tp->snd_una+1 == th->th_ack)) + tp->snd_una++; tcp_timer_activate(tp, TT_KEEP, TP_KEEPIDLE(tp)); } @@ -2416,8 +2419,12 @@ * snd_cwnd reduction that occurs when a TFO SYN|ACK * is retransmitted. */ - if (!IS_FASTOPEN(tp->t_flags)) + if (!IS_FASTOPEN(tp->t_flags)) { cc_conn_init(tp); + if ((tlen == 0) && + (tp->snd_una+1 == th->th_ack)) + tp->snd_una++; + } tcp_timer_activate(tp, TT_KEEP, TP_KEEPIDLE(tp)); } /* Index: sys/netinet/tcp_stacks/rack.c =================================================================== --- sys/netinet/tcp_stacks/rack.c +++ sys/netinet/tcp_stacks/rack.c @@ -5266,6 +5266,9 @@ TCP_PROBE5(connect__established, NULL, tp, mtod(m, const char *), tp, th); cc_conn_init(tp); + if ((tlen == 0) && + (tp->snd_una+1 == th->th_ack)) + tp->snd_una++; } } else { /* @@ -5481,8 +5484,12 @@ * is not harmless as it would undo the snd_cwnd reduction * that occurs when a TFO SYN|ACK is retransmitted. */ - if (!IS_FASTOPEN(tp->t_flags)) + if (!IS_FASTOPEN(tp->t_flags)) { cc_conn_init(tp); + if ((tlen == 0) && + (tp->snd_una+1 == th->th_ack)) + tp->snd_una++; + } } /* * If segment contains data or ACK, will call tcp_reass() later; if