From caa7acf5c55a78ef4f7addfb94da0ad788f59a75 Mon Sep 17 00:00:00 2001 From: Nathan Skrzypczak Date: Wed, 2 Oct 2019 10:02:05 +0200 Subject: session: add is_migrating flag Type: fix Add SESSION_F_IS_MIGRATING flag for session. It is set by the session layer before poking the transport for migration. It's the transport responsibility to unset the flag & act apropriatly if RX happens on a migrating session. Change-Id: Ie722917f1cf9344d8f041cad4ed8b064fb5853b6 Signed-off-by: Nathan Skrzypczak --- src/vnet/session/session.c | 1 + src/vnet/session/session_types.h | 1 + 2 files changed, 2 insertions(+) (limited to 'src/vnet') diff --git a/src/vnet/session/session.c b/src/vnet/session/session.c index be62d929363..f1360226152 100644 --- a/src/vnet/session/session.c +++ b/src/vnet/session/session.c @@ -799,6 +799,7 @@ session_dgram_connect_notify (transport_connection_t * tc, new_s->rx_fifo->master_session_index = new_s->session_index; new_s->rx_fifo->master_thread_index = new_s->thread_index; new_s->session_state = SESSION_STATE_READY; + new_s->flags |= SESSION_F_IS_MIGRATING; session_lookup_add_connection (tc, session_handle (new_s)); /* diff --git a/src/vnet/session/session_types.h b/src/vnet/session/session_types.h index bf45855e264..03f7096c4b8 100644 --- a/src/vnet/session/session_types.h +++ b/src/vnet/session/session_types.h @@ -148,6 +148,7 @@ typedef enum session_flags_ SESSION_F_RX_EVT = 1, SESSION_F_PROXY = (1 << 1), SESSION_F_CUSTOM_TX = (1 << 2), + SESSION_F_IS_MIGRATING = (1 << 3), } session_flags_t; typedef struct session_ -- cgit 1.2.3-korg