]> git.itanic.dy.fi Git - linux-stable/commit
tcp_bbr: fix pacing_gain to always be unity when using lt_bw
authorNeal Cardwell <ncardwell@google.com>
Wed, 31 Jan 2018 20:43:05 +0000 (15:43 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 12 Feb 2018 06:07:20 +0000 (07:07 +0100)
commita742a89695ce06f064406ab6fcd64110b12b9917
tree1ab0a0ba552ae5c8341dbab4c75b861c673e6b10
parent759f8b0b3ad8374b7f5750e53690804d9dd7e482
tcp_bbr: fix pacing_gain to always be unity when using lt_bw

[ Upstream commit 3aff3b4b986e51bcf4ab249e5d48d39596e0df6a ]

This commit fixes the pacing_gain to remain at BBR_UNIT (1.0) when
using lt_bw and returning from the PROBE_RTT state to PROBE_BW.

Previously, when using lt_bw, upon exiting PROBE_RTT and entering
PROBE_BW the bbr_reset_probe_bw_mode() code could sometimes randomly
end up with a cycle_idx of 0 and hence have bbr_advance_cycle_phase()
set a pacing gain above 1.0. In such cases this would result in a
pacing rate that is 1.25x higher than intended, potentially resulting
in a high loss rate for a little while until we stop using the lt_bw a
bit later.

This commit is a stable candidate for kernels back as far as 4.9.

Fixes: 0f8782ea1497 ("tcp_bbr: add BBR congestion control")
Signed-off-by: Neal Cardwell <ncardwell@google.com>
Signed-off-by: Yuchung Cheng <ycheng@google.com>
Signed-off-by: Soheil Hassas Yeganeh <soheil@google.com>
Reported-by: Beyers Cronje <bcronje@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/ipv4/tcp_bbr.c