aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/session/session.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/vnet/session/session.h')
-rw-r--r--src/vnet/session/session.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/vnet/session/session.h b/src/vnet/session/session.h
index b24e22923f1..6908a568a0f 100644
--- a/src/vnet/session/session.h
+++ b/src/vnet/session/session.h
@@ -450,20 +450,27 @@ session_get_from_handle_safe (u64 handle)
}
always_inline u32
-stream_session_max_rx_enqueue (transport_connection_t * tc)
+transport_max_rx_enqueue (transport_connection_t * tc)
{
stream_session_t *s = session_get (tc->s_index, tc->thread_index);
return svm_fifo_max_enqueue (s->server_rx_fifo);
}
always_inline u32
-stream_session_rx_fifo_size (transport_connection_t * tc)
+transport_rx_fifo_size (transport_connection_t * tc)
{
stream_session_t *s = session_get (tc->s_index, tc->thread_index);
return s->server_rx_fifo->nitems;
}
always_inline u32
+transport_tx_fifo_size (transport_connection_t * tc)
+{
+ stream_session_t *s = session_get (tc->s_index, tc->thread_index);
+ return s->server_tx_fifo->nitems;
+}
+
+always_inline u32
session_get_index (stream_session_t * s)
{
return (s - session_manager_main.sessions[s->thread_index]);