aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/session/session.c
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2018-06-10 14:41:23 -0700
committerMarco Varlese <marco.varlese@suse.de>2018-06-11 14:08:20 +0000
commit40903ac34f89d9e2ad775e98b7bcec5b7feb0207 (patch)
tree550a152e6a9359248ec50ffbeb0063b564bbcb48 /src/vnet/session/session.c
parentd723161e038d00e59766aa67a6a0dcc350227e4b (diff)
udp: fix for multiple workers and add test
Since the main thread is not used for session polling anymore, when vpp is started with multiple wokers, allocate connections on the first. Also add a simple udp make test. Change-Id: Id869f5d89e0fced51048f0384fa86a5022258b7c Signed-off-by: Florin Coras <fcoras@cisco.com>
Diffstat (limited to 'src/vnet/session/session.c')
-rw-r--r--src/vnet/session/session.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/vnet/session/session.c b/src/vnet/session/session.c
index ee02526c190..cfba31ec406 100644
--- a/src/vnet/session/session.c
+++ b/src/vnet/session/session.c
@@ -142,7 +142,8 @@ session_alloc_for_connection (transport_connection_t * tc)
stream_session_t *s;
u32 thread_index = tc->thread_index;
- ASSERT (thread_index == vlib_get_thread_index ());
+ ASSERT (thread_index == vlib_get_thread_index ()
+ || transport_protocol_is_cl (tc->proto));
s = session_alloc (thread_index);
s->session_type = session_type_from_proto_and_ip (tc->proto, tc->is_ip4);