diff options
author | David S. Miller <davem@davemloft.net> | 2014-09-05 17:49:39 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-09-05 17:49:39 -0700 |
commit | 3aff50170a37d032c86d10c1815e875e8af0aa1a (patch) | |
tree | ebaba03f755dfbe9d942fbe610ce3aecd1b0fc33 /net/ipv4/tcp_input.c | |
parent | 2ba38943ba190eb6a494262003e23187d1b40fb4 (diff) | |
parent | 7faee5c0d514162853a343d93e4a0b6bb8bfec21 (diff) |
Merge branch 'tcp'
Eric Dumazet says:
====================
tcp: deduplicate TCP_SKB_CB(skb)->when
TCP_SKB_CB(skb)->when has different meaning in output and input paths.
In output path, it contains a timestamp.
In input path, it contains an ISN, chosen by tcp_timewait_state_process()
Its usage in output path is obsolete after usec timestamping.
Lets simplify and clean this.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/tcp_input.c')
-rw-r--r-- | net/ipv4/tcp_input.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c index aba4926ca09..f97003ad0af 100644 --- a/net/ipv4/tcp_input.c +++ b/net/ipv4/tcp_input.c @@ -2967,7 +2967,8 @@ void tcp_rearm_rto(struct sock *sk) if (icsk->icsk_pending == ICSK_TIME_EARLY_RETRANS || icsk->icsk_pending == ICSK_TIME_LOSS_PROBE) { struct sk_buff *skb = tcp_write_queue_head(sk); - const u32 rto_time_stamp = TCP_SKB_CB(skb)->when + rto; + const u32 rto_time_stamp = + tcp_skb_timestamp(skb) + rto; s32 delta = (s32)(rto_time_stamp - tcp_time_stamp); /* delta may not be positive if the socket is locked * when the retrans timer fires and is rescheduled. @@ -5906,7 +5907,7 @@ int tcp_conn_request(struct request_sock_ops *rsk_ops, struct request_sock *req; struct tcp_sock *tp = tcp_sk(sk); struct dst_entry *dst = NULL; - __u32 isn = TCP_SKB_CB(skb)->when; + __u32 isn = TCP_SKB_CB(skb)->tcp_tw_isn; bool want_cookie = false, fastopen; struct flowi fl; struct tcp_fastopen_cookie foc = { .len = -1 }; |