aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/session/session.c
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2018-10-15 21:35:42 -0700
committerMarco Varlese <marco.varlese@suse.de>2018-10-17 07:33:24 +0000
commit7d76878ab3eea9d233d569d9b714a40924fbaa8b (patch)
tree19a2a0a1d9bc7f64bc508b908b3e75098fa08b92 /src/vnet/session/session.c
parent84112dd4f98e5a31a8c7340a741f89e77fd03363 (diff)
tls: fix multi threaded medium scale test (VPP-1457)
- ensure session enqueue epoch does not wrap between two enqueues - use 3 states for echo clients app, to distinguish between starting and closing phases - force tcp fin retransmit if out of buffers while sending a fin Change-Id: I6f2cab46affd1148aba2a33fb6d58bcc54f32805 Signed-off-by: Florin Coras <fcoras@cisco.com>
Diffstat (limited to 'src/vnet/session/session.c')
-rw-r--r--src/vnet/session/session.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/vnet/session/session.c b/src/vnet/session/session.c
index 83b96d317dc..7b50950fe01 100644
--- a/src/vnet/session/session.c
+++ b/src/vnet/session/session.c
@@ -153,7 +153,7 @@ session_free (stream_session_t * s)
memset (s, 0xFA, sizeof (*s));
}
-static void
+void
session_free_w_fifos (stream_session_t * s)
{
segment_manager_dealloc_fifos (s->svm_segment_index, s->server_rx_fifo,
@@ -197,7 +197,7 @@ session_alloc_for_connection (transport_connection_t * tc)
s = session_alloc (thread_index);
s->session_type = session_type_from_proto_and_ip (tc->proto, tc->is_ip4);
s->session_state = SESSION_STATE_CONNECTING;
- s->enqueue_epoch = ~0;
+ s->enqueue_epoch = (u64) ~ 0;
/* Attach transport to session and vice versa */
s->connection_index = tc->c_index;
@@ -393,7 +393,7 @@ session_enqueue_stream_connection (transport_connection_t * tc,
* by calling stream_server_flush_enqueue_events () */
session_manager_main_t *smm = vnet_get_session_manager_main ();
u32 thread_index = s->thread_index;
- u32 enqueue_epoch = smm->current_enqueue_epoch[tc->proto][thread_index];
+ u64 enqueue_epoch = smm->current_enqueue_epoch[tc->proto][thread_index];
if (s->enqueue_epoch != enqueue_epoch)
{
@@ -434,7 +434,7 @@ session_enqueue_dgram_connection (stream_session_t * s,
* by calling stream_server_flush_enqueue_events () */
session_manager_main_t *smm = vnet_get_session_manager_main ();
u32 thread_index = s->thread_index;
- u32 enqueue_epoch = smm->current_enqueue_epoch[proto][thread_index];
+ u64 enqueue_epoch = smm->current_enqueue_epoch[proto][thread_index];
if (s->enqueue_epoch != enqueue_epoch)
{