summaryrefslogtreecommitdiffstats
path: root/src/vnet/tls/tls.h
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2019-01-14 23:33:46 -0800
committerDave Barach <openvpp@barachs.net>2019-01-17 20:31:54 +0000
commit58a93e8ef288b0bae75ec7186ba96bdcaf85d0d4 (patch)
tree2345aa718a507bd8bfc1857d705e9614e408be18 /src/vnet/tls/tls.h
parent72b04288d9a670829050a6ca5d931ae5b55b33ed (diff)
tls: preallocate app sessions on connect/accept
Avoid allocating session and possibly reallocating thread session pool on builtin session rx. Change-Id: I70e7c604678b44ce8d22603489e247a2c5faa439 Signed-off-by: Florin Coras <fcoras@cisco.com>
Diffstat (limited to 'src/vnet/tls/tls.h')
-rw-r--r--src/vnet/tls/tls.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/vnet/tls/tls.h b/src/vnet/tls/tls.h
index 09f1bdc7b07..c4f04673f2e 100644
--- a/src/vnet/tls/tls.h
+++ b/src/vnet/tls/tls.h
@@ -39,7 +39,10 @@
typedef CLIB_PACKED (struct tls_cxt_id_
{
u32 parent_app_index;
- session_handle_t app_session_handle;
+ union {
+ session_handle_t app_session_handle;
+ u32 parent_app_api_ctx;
+ };
session_handle_t tls_session_handle;
u32 ssl_ctx;
u32 listener_ctx_index;
@@ -67,7 +70,7 @@ typedef struct tls_ctx_
#define tls_ctx_handle c_c_index
/* Temporary storage for session open opaque. Overwritten once
* underlying tcp connection is established */
-#define parent_app_api_context c_s_index
+#define parent_app_api_context c_tls_ctx_id.parent_app_api_ctx
u8 is_passive_close;
u8 resume;