tcp: address problems caused by EDT misshaps
authorEric Dumazet <edumazet@google.com>
Sat, 24 Nov 2018 17:12:24 +0000 (09:12 -0800)
committerDavid S. Miller <davem@davemloft.net>
Sun, 25 Nov 2018 01:41:37 +0000 (17:41 -0800)
commit9efdda4e3abed13f0903b7b6e4d4c2102019440a
treea65b654f1c7453e5554619e9501670319c8085c8
parentd146194f31c96f9b260c5a1cf1592d2e7f82a2e2
tcp: address problems caused by EDT misshaps

When a qdisc setup including pacing FQ is dismantled and recreated,
some TCP packets are sent earlier than instructed by TCP stack.

TCP can be fooled when ACK comes back, because the following
operation can return a negative value.

    tcp_time_stamp(tp) - tp->rx_opt.rcv_tsecr;

Some paths in TCP stack were not dealing properly with this,
this patch addresses four of them.

Fixes: ab408b6dc744 ("tcp: switch tcp and sch_fq to new earliest departure time model")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/tcp_input.c
net/ipv4/tcp_timer.c