]> git.karo-electronics.de Git - karo-tx-linux.git/commit
tcp: don't apply tsoffset if rcv_tsecr is zero
authorAndrew Vagin <avagin@openvz.org>
Tue, 27 Aug 2013 08:21:55 +0000 (12:21 +0400)
committerDavid S. Miller <davem@davemloft.net>
Thu, 29 Aug 2013 19:11:12 +0000 (15:11 -0400)
commite3e12028315749b7fa2edbc37328e5847be9ede9
tree56b91f5c9bf69c923b5ca397873145777aca2db4
parentc7781a6e3c4a9a17e144ec2db00ebfea327bd627
tcp: don't apply tsoffset if rcv_tsecr is zero

The zero value means that tsecr is not valid, so it's a special case.

tsoffset is used to customize tcp_time_stamp for one socket.
tsoffset is usually zero, it's used when a socket was moved from one
host to another host.

Currently this issue affects logic of tcp_rcv_rtt_measure_ts. Due to
incorrect value of rcv_tsecr, tcp_rcv_rtt_measure_ts sets rto to
TCP_RTO_MAX.

Cc: Pavel Emelyanov <xemul@parallels.com>
Cc: Eric Dumazet <eric.dumazet@gmail.com>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Alexey Kuznetsov <kuznet@ms2.inr.ac.ru>
Cc: James Morris <jmorris@namei.org>
Cc: Hideaki YOSHIFUJI <yoshfuji@linux-ipv6.org>
Cc: Patrick McHardy <kaber@trash.net>
Reported-by: Cyrill Gorcunov <gorcunov@openvz.org>
Signed-off-by: Andrey Vagin <avagin@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/tcp_input.c