diff options
Diffstat (limited to 'net/ipv4/tcp_ipv4.c')
-rw-r--r-- | net/ipv4/tcp_ipv4.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/net/ipv4/tcp_ipv4.c b/net/ipv4/tcp_ipv4.c index bea17f1e8302..dc415c66a33a 100644 --- a/net/ipv4/tcp_ipv4.c +++ b/net/ipv4/tcp_ipv4.c | |||
@@ -155,7 +155,8 @@ int tcp_twsk_unique(struct sock *sk, struct sock *sktw, void *twp) | |||
155 | and use initial timestamp retrieved from peer table. | 155 | and use initial timestamp retrieved from peer table. |
156 | */ | 156 | */ |
157 | if (tcptw->tw_ts_recent_stamp && | 157 | if (tcptw->tw_ts_recent_stamp && |
158 | (!twp || (reuse && get_seconds() - tcptw->tw_ts_recent_stamp > 1))) { | 158 | (!twp || (reuse && time_after32(ktime_get_seconds(), |
159 | tcptw->tw_ts_recent_stamp)))) { | ||
159 | tp->write_seq = tcptw->tw_snd_nxt + 65535 + 2; | 160 | tp->write_seq = tcptw->tw_snd_nxt + 65535 + 2; |
160 | if (tp->write_seq == 0) | 161 | if (tp->write_seq == 0) |
161 | tp->write_seq = 1; | 162 | tp->write_seq = 1; |