tcp: fix infinite cwnd in tcp_complete_cwr()
authorYuchung Cheng <ycheng@google.com>
Mon, 30 Apr 2012 06:00:18 +0000 (06:00 +0000)
committerDavid S. Miller <davem@davemloft.net>
Mon, 30 Apr 2012 17:44:39 +0000 (13:44 -0400)
commit1cebce36d660c83bd1353e41f3e66abd4686f215
treecd82ebc7c67f3d67e4de202dd3dafbb347f2324c
parent05be18241e83d2ac6b656c8f924e74b3998c173f
tcp: fix infinite cwnd in tcp_complete_cwr()

When the cwnd reduction is done, ssthresh may be infinite
if TCP enters CWR via ECN or F-RTO. If cwnd is not undone, i.e.,
undo_marker is set, tcp_complete_cwr() falsely set cwnd to the
infinite ssthresh value. The correct operation is to keep cwnd
intact because it has been updated in ECN or F-RTO.

Signed-off-by: Yuchung Cheng <ycheng@google.com>
Acked-by: Neal Cardwell <ncardwell@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/tcp_input.c