diff options
author | Neal Cardwell <ncardwell@google.com> | 2014-06-30 15:09:49 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-07-07 22:26:37 -0400 |
commit | 86c6a2c75ab97fe31844985169e26aea335432f9 (patch) | |
tree | e3d15ca2ac9a89fbd5399ac6a1886822176fc392 /net/ipv4 | |
parent | 0b88e7042a221a0318d726017b0f97aa42066826 (diff) |
tcp: switch snt_synack back to measuring transmit time of first SYNACK
Always store in snt_synack the time at which the server received the
first client SYN and attempted to send the first SYNACK.
Recent commit aa27fc501 ("tcp: tcp_v[46]_conn_request: fix snt_synack
initialization") resolved an inconsistency between IPv4 and IPv6 in
the initialization of snt_synack. This commit brings back the idea
from 843f4a55e (tcp: use tcp_v4_send_synack on first SYN-ACK), which
was going for the original behavior of snt_synack from the commit
where it was added in 9ad7c049f0f79 ("tcp: RFC2988bis + taking RTT
sample from 3WHS for the passive open side") in v3.1.
In addition to being simpler (and probably a tiny bit faster),
unconditionally storing the time of the first SYNACK attempt has been
useful because it allows calculating a performance metric quantifying
how long it took to establish a passive TCP connection.
Signed-off-by: Neal Cardwell <ncardwell@google.com>
Signed-off-by: Yuchung Cheng <ycheng@google.com>
Cc: Octavian Purdila <octavian.purdila@intel.com>
Cc: Jerry Chu <hkchu@google.com>
Acked-by: Octavian Purdila <octavian.purdila@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4')
-rw-r--r-- | net/ipv4/tcp_ipv4.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/net/ipv4/tcp_ipv4.c b/net/ipv4/tcp_ipv4.c index 5dfebd2f2e38..52d0f6a1ec2c 100644 --- a/net/ipv4/tcp_ipv4.c +++ b/net/ipv4/tcp_ipv4.c | |||
@@ -838,8 +838,6 @@ static int tcp_v4_send_synack(struct sock *sk, struct dst_entry *dst, | |||
838 | ireq->ir_rmt_addr, | 838 | ireq->ir_rmt_addr, |
839 | ireq->opt); | 839 | ireq->opt); |
840 | err = net_xmit_eval(err); | 840 | err = net_xmit_eval(err); |
841 | if (!tcp_rsk(req)->snt_synack && !err) | ||
842 | tcp_rsk(req)->snt_synack = tcp_time_stamp; | ||
843 | } | 841 | } |
844 | 842 | ||
845 | return err; | 843 | return err; |