aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/tcp_timer.c
diff options
context:
space:
mode:
authorEric Dumazet <edumazet@google.com>2018-09-28 13:28:44 -0400
committerDavid S. Miller <davem@davemloft.net>2018-10-02 02:18:51 -0400
commitfb420d5d91c1274d5966917725e71f27ed092a85 (patch)
treef4a5a44cf2c8c53e9af214bc686c5a25736bca5e /net/ipv4/tcp_timer.c
parent0ed3015c9964dab7a1693b3e40650f329c16691e (diff)
tcp/fq: move back to CLOCK_MONOTONIC
In the recent TCP/EDT patch series, I switched TCP and sch_fq clocks from MONOTONIC to TAI, in order to meet the choice done earlier for sch_etf packet scheduler. But sure enough, this broke some setups were the TAI clock jumps forward (by almost 50 year...), as reported by Leonard Crestez. If we want to converge later, we'll probably need to add an skb field to differentiate the clock bases, or a socket option. In the meantime, an UDP application will need to use CLOCK_MONOTONIC base for its SCM_TXTIME timestamps if using fq packet scheduler. Fixes: 72b0094f9182 ("tcp: switch tcp_clock_ns() to CLOCK_TAI base") Fixes: 142537e41923 ("net_sched: sch_fq: switch to CLOCK_TAI") Fixes: fd2bca2aa789 ("tcp: switch internal pacing timer to CLOCK_TAI") Signed-off-by: Eric Dumazet <edumazet@google.com> Reported-by: Leonard Crestez <leonard.crestez@nxp.com> Tested-by: Leonard Crestez <leonard.crestez@nxp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/tcp_timer.c')
-rw-r--r--net/ipv4/tcp_timer.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv4/tcp_timer.c b/net/ipv4/tcp_timer.c
index 4f661e178da8..61023d50cd60 100644
--- a/net/ipv4/tcp_timer.c
+++ b/net/ipv4/tcp_timer.c
@@ -758,7 +758,7 @@ void tcp_init_xmit_timers(struct sock *sk)
758{ 758{
759 inet_csk_init_xmit_timers(sk, &tcp_write_timer, &tcp_delack_timer, 759 inet_csk_init_xmit_timers(sk, &tcp_write_timer, &tcp_delack_timer,
760 &tcp_keepalive_timer); 760 &tcp_keepalive_timer);
761 hrtimer_init(&tcp_sk(sk)->pacing_timer, CLOCK_TAI, 761 hrtimer_init(&tcp_sk(sk)->pacing_timer, CLOCK_MONOTONIC,
762 HRTIMER_MODE_ABS_PINNED_SOFT); 762 HRTIMER_MODE_ABS_PINNED_SOFT);
763 tcp_sk(sk)->pacing_timer.function = tcp_pace_kick; 763 tcp_sk(sk)->pacing_timer.function = tcp_pace_kick;
764 764