summaryrefslogtreecommitdiffstats
path: root/src/vnet/tcp/tcp_output.c
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2021-04-02 18:32:00 -0700
committerDave Barach <openvpp@barachs.net>2021-04-05 21:07:22 +0000
commit8f10b9050dc6318d7ccb3982eec2ed742752c6ea (patch)
tree64123a2faaf179db0558023a1a6de8c147528714 /src/vnet/tcp/tcp_output.c
parente2daada1d58368b7e77c2990e680bf58e4d94f2e (diff)
tcp: time infra improvements
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I998c0686f9f7dc556dda8b28e23bbed127d0aafc
Diffstat (limited to 'src/vnet/tcp/tcp_output.c')
-rw-r--r--src/vnet/tcp/tcp_output.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/vnet/tcp/tcp_output.c b/src/vnet/tcp/tcp_output.c
index 235a59be0b3..928e8249eb1 100644
--- a/src/vnet/tcp/tcp_output.c
+++ b/src/vnet/tcp/tcp_output.c
@@ -176,7 +176,7 @@ tcp_make_syn_options (tcp_connection_t * tc, tcp_options_t * opts)
len += TCP_OPTION_LEN_WINDOW_SCALE;
opts->flags |= TCP_OPTS_FLAG_TSTAMP;
- opts->tsval = tcp_time_now ();
+ opts->tsval = tcp_time_tstamp (tc->c_thread_index);
opts->tsecr = 0;
len += TCP_OPTION_LEN_TIMESTAMP;
@@ -210,7 +210,7 @@ tcp_make_synack_options (tcp_connection_t * tc, tcp_options_t * opts)
if (tcp_opts_tstamp (&tc->rcv_opts))
{
opts->flags |= TCP_OPTS_FLAG_TSTAMP;
- opts->tsval = tcp_time_now ();
+ opts->tsval = tcp_time_tstamp (tc->c_thread_index);
opts->tsecr = tc->tsval_recent;
len += TCP_OPTION_LEN_TIMESTAMP;
}
@@ -2188,7 +2188,7 @@ tcp46_output_inline (vlib_main_t * vm, vlib_node_runtime_t * node,
from = vlib_frame_vector_args (frame);
n_left_from = frame->n_vectors;
- tcp_set_time_now (tcp_get_worker (thread_index));
+ tcp_update_time_now (tcp_get_worker (thread_index));
if (PREDICT_FALSE (node->flags & VLIB_NODE_FLAG_TRACE))
tcp46_output_trace_frame (vm, node, from, n_left_from);