aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/session/session_node.c
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2019-10-06 14:06:14 -0700
committerFlorin Coras <florin.coras@gmail.com>2019-10-10 21:23:14 +0000
commitc31dc31f84961033ecb6354811e0c360b6cf5f79 (patch)
tree46224d5f2b9d126cb6bd5fa289a18186cb172aa5 /src/vnet/session/session_node.c
parent71a5da0c8dfa12ff012c8c101cf4d2b29fa0b6e3 (diff)
tcp: improve pacing after idle send periods
Rest pacer on ack reception if we haven't recently sent anything. Type: feature Change-Id: I820bacd81b65130052dfafbfcbe6ca4553069fbc Signed-off-by: Florin Coras <fcoras@cisco.com>
Diffstat (limited to 'src/vnet/session/session_node.c')
-rw-r--r--src/vnet/session/session_node.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/vnet/session/session_node.c b/src/vnet/session/session_node.c
index 9e53718b8dd..f51b892736a 100644
--- a/src/vnet/session/session_node.c
+++ b/src/vnet/session/session_node.c
@@ -845,6 +845,7 @@ session_tx_fifo_read_and_snd_i (session_worker_t * wrk,
{
if (ctx->transport_vft->flush_data)
ctx->transport_vft->flush_data (ctx->tc);
+ e->event_type = SESSION_IO_EVT_TX;
}
if (ctx->s->flags & SESSION_F_CUSTOM_TX)
@@ -883,7 +884,12 @@ session_tx_fifo_read_and_snd_i (session_worker_t * wrk,
session_tx_set_dequeue_params (vm, ctx, max_burst, peek_data);
if (PREDICT_FALSE (!ctx->max_len_to_snd))
- return SESSION_TX_NO_DATA;
+ {
+ transport_connection_tx_pacer_reset_bucket (ctx->tc,
+ vm->clib_time.
+ last_cpu_time);
+ return SESSION_TX_NO_DATA;
+ }
n_bufs_needed = ctx->n_segs_per_evt * ctx->n_bufs_per_seg;
vec_validate_aligned (wrk->tx_buffers, n_bufs_needed - 1,