summaryrefslogtreecommitdiffstats
path: root/src/plugins/tlsmbedtls
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2020-03-23 15:34:22 +0000
committerDave Barach <openvpp@barachs.net>2020-04-04 17:34:13 +0000
commit9f86d225ab4f3dccbf61383a75d6af7d321a204e (patch)
tree28051dc383a6214a20854fd21a460281cd8c373c /src/plugins/tlsmbedtls
parented8db52539a8d8239a9a43bea53328d25eb47f0d (diff)
session tls: support tls descheduling
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ieb8bb9c6deb92479fdd3e045778fe5ae4782d1ea
Diffstat (limited to 'src/plugins/tlsmbedtls')
-rw-r--r--src/plugins/tlsmbedtls/tls_mbedtls.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/plugins/tlsmbedtls/tls_mbedtls.c b/src/plugins/tlsmbedtls/tls_mbedtls.c
index 8ac736ae6f3..3fccba2ec5a 100644
--- a/src/plugins/tlsmbedtls/tls_mbedtls.c
+++ b/src/plugins/tlsmbedtls/tls_mbedtls.c
@@ -431,7 +431,8 @@ mbedtls_ctx_handshake_rx (tls_ctx_t * ctx)
}
static int
-mbedtls_ctx_write (tls_ctx_t * ctx, session_t * app_session, u32 max_write)
+mbedtls_ctx_write (tls_ctx_t * ctx, session_t * app_session,
+ transport_send_params_t * sp)
{
mbedtls_ctx_t *mc = (mbedtls_ctx_t *) ctx;
u8 thread_index = ctx->c_thread_index;
@@ -446,7 +447,7 @@ mbedtls_ctx_write (tls_ctx_t * ctx, session_t * app_session, u32 max_write)
if (!deq_max)
return 0;
- deq_max = clib_min (deq_max, max_write);
+ deq_max = clib_min (deq_max, sp->max_burst_size);
tls_session = session_get_from_handle (ctx->tls_session_handle);
enq_max = svm_fifo_max_enqueue_prod (tls_session->tx_fifo);
deq_now = clib_min (deq_max, TLS_CHUNK_SIZE);