From 7428eaa4a1ae55052825cdc6c0a9ae6c4f8748ac Mon Sep 17 00:00:00 2001 From: Florin Coras Date: Mon, 11 Dec 2023 16:04:57 -0800 Subject: session: support for cl port reuse Adds support for connectionless listener port reuse. Until now, cl listeners had fifos allocated to them and therefore only one app worker could ever listen, i.e., a session cannot have multiple fifos. To circumvent the limitation, this separates the fifos from the listener by allocating new cl sessions for each app worker that reuses the app listener. Flows are hashed to app worker cl sessions but, for now, this is not a consistent/fixed hash. Type: improvement Signed-off-by: Florin Coras Change-Id: Ic6533cd47f2765903669f88c288bd592fb17a19e --- src/vnet/session/application.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/vnet/session/application.h') diff --git a/src/vnet/session/application.h b/src/vnet/session/application.h index 5505d91ea09..7c63b90ac5a 100644 --- a/src/vnet/session/application.h +++ b/src/vnet/session/application.h @@ -106,6 +106,8 @@ typedef struct app_listener_ session_handle_t ls_handle; /**< session handle of the local or global listening session that also identifies the app listener */ + u32 *cl_listeners; /**< vector that maps app workers to their + cl sessions with fifos */ } app_listener_t; typedef enum app_rx_mq_flags_ @@ -254,6 +256,8 @@ void app_listener_cleanup (app_listener_t * app_listener); session_handle_t app_listener_handle (app_listener_t * app_listener); app_listener_t *app_listener_lookup (application_t * app, session_endpoint_cfg_t * sep); +session_t *app_listener_select_wrk_cl_session (session_t *ls, + session_dgram_hdr_t *hdr); /** * Get app listener handle for listening session @@ -280,6 +284,7 @@ app_listener_t *app_listener_get_w_handle (session_handle_t handle); app_listener_t *app_listener_get_w_session (session_t * ls); session_t *app_listener_get_session (app_listener_t * al); session_t *app_listener_get_local_session (app_listener_t * al); +session_t *app_listener_get_wrk_cl_session (app_listener_t *al, u32 wrk_index); application_t *application_get (u32 index); application_t *application_get_if_valid (u32 index); -- cgit 1.2.3-korg