Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

tcp: fix stretch ACK bugs in BIC

Changes BIC to properly handle stretch ACKs in additive
increase mode by passing in the count of ACKed packets
to tcp_cong_avoid_ai().

Signed-off-by: Pengcheng Yang <yangpc@wangsu.com>
Acked-by: Neal Cardwell <ncardwell@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Pengcheng Yang and committed by
David S. Miller
be0d935e 86e85bf6

+6 -5
+6 -5
net/ipv4/tcp_bic.c
··· 145 145 if (!tcp_is_cwnd_limited(sk)) 146 146 return; 147 147 148 - if (tcp_in_slow_start(tp)) 149 - tcp_slow_start(tp, acked); 150 - else { 151 - bictcp_update(ca, tp->snd_cwnd); 152 - tcp_cong_avoid_ai(tp, ca->cnt, 1); 148 + if (tcp_in_slow_start(tp)) { 149 + acked = tcp_slow_start(tp, acked); 150 + if (!acked) 151 + return; 153 152 } 153 + bictcp_update(ca, tp->snd_cwnd); 154 + tcp_cong_avoid_ai(tp, ca->cnt, acked); 154 155 } 155 156 156 157 /*