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

tcp: fix under-evaluated ssthresh in TCP Vegas

With the commit 76174004a0f19785 (tcp: do not slow start when cwnd equals
ssthresh), the comparison to the reduced cwnd in tcp_vegas_ssthresh() would
under-evaluate the ssthresh.

Signed-off-by: Hoang Tran <hoang.tran@uclouvain.be>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Hoang Tran and committed by
David S. Miller
cf5d74b8 5af48b59

+1 -1
+1 -1
net/ipv4/tcp_vegas.c
··· 158 158 159 159 static inline u32 tcp_vegas_ssthresh(struct tcp_sock *tp) 160 160 { 161 - return min(tp->snd_ssthresh, tp->snd_cwnd-1); 161 + return min(tp->snd_ssthresh, tp->snd_cwnd); 162 162 } 163 163 164 164 static void tcp_vegas_cong_avoid(struct sock *sk, u32 ack, u32 acked)