diff options
author | Ilpo Järvinen <ilpo.jarvinen@helsinki.fi> | 2009-04-14 05:08:53 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-04-14 05:08:53 -0400 |
commit | 86bcebafc5e7f5163ccf828792fe694b112ed6fa (patch) | |
tree | fa383567eae0553e73a834ad97f64e07d1b47dfe /net/ipv4 | |
parent | 1a31f2042e938f1b467aa3d807cc5666352bf8a3 (diff) |
tcp: fix >2 iw selection
A long-standing feature in tcp_init_metrics() is such that
any of its goto reset prevents call to tcp_init_cwnd().
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4')
-rw-r--r-- | net/ipv4/tcp_input.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c index 2bc8e27a163d..c96a6bb25430 100644 --- a/net/ipv4/tcp_input.c +++ b/net/ipv4/tcp_input.c | |||
@@ -928,6 +928,8 @@ static void tcp_init_metrics(struct sock *sk) | |||
928 | tcp_set_rto(sk); | 928 | tcp_set_rto(sk); |
929 | if (inet_csk(sk)->icsk_rto < TCP_TIMEOUT_INIT && !tp->rx_opt.saw_tstamp) | 929 | if (inet_csk(sk)->icsk_rto < TCP_TIMEOUT_INIT && !tp->rx_opt.saw_tstamp) |
930 | goto reset; | 930 | goto reset; |
931 | |||
932 | cwnd: | ||
931 | tp->snd_cwnd = tcp_init_cwnd(tp, dst); | 933 | tp->snd_cwnd = tcp_init_cwnd(tp, dst); |
932 | tp->snd_cwnd_stamp = tcp_time_stamp; | 934 | tp->snd_cwnd_stamp = tcp_time_stamp; |
933 | return; | 935 | return; |
@@ -942,6 +944,7 @@ reset: | |||
942 | tp->mdev = tp->mdev_max = tp->rttvar = TCP_TIMEOUT_INIT; | 944 | tp->mdev = tp->mdev_max = tp->rttvar = TCP_TIMEOUT_INIT; |
943 | inet_csk(sk)->icsk_rto = TCP_TIMEOUT_INIT; | 945 | inet_csk(sk)->icsk_rto = TCP_TIMEOUT_INIT; |
944 | } | 946 | } |
947 | goto cwnd; | ||
945 | } | 948 | } |
946 | 949 | ||
947 | static void tcp_update_reordering(struct sock *sk, const int metric, | 950 | static void tcp_update_reordering(struct sock *sk, const int metric, |