tcp: avoid cwnd moderation in undo
authorYuchung Cheng <ycheng@google.com>
Mon, 14 Mar 2011 10:57:03 +0000 (10:57 +0000)
committerDavid S. Miller <davem@davemloft.net>
Wed, 23 Mar 2011 02:36:08 +0000 (19:36 -0700)
commit67d4120a1793138bc9f4a6eb61d0fc5298ed97e0
tree24ffa212d26a6048675a2b7f2c1a4371e62c9f6d
parenta7bff75b087e7a355838a32efe61707cfa73c194
tcp: avoid cwnd moderation in undo

In the current undo logic, cwnd is moderated after it was restored
to the value prior entering fast-recovery. It was moderated first
in tcp_try_undo_recovery then again in tcp_complete_cwr.

Since the undo indicates recovery was false, these moderations
are not necessary. If the undo is triggered when most of the
outstanding data have been acknowledged, the (restored) cwnd is
falsely pulled down to a small value.

This patch removes these cwnd moderations if cwnd is undone
  a) during fast-recovery
b) by receiving DSACKs past fast-recovery

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