From 33e002b168a211b1d620f4fffbd3752c8f1f2129 Mon Sep 17 00:00:00 2001 From: Dave Wallace Date: Wed, 6 Sep 2017 01:20:02 -0400 Subject: Fix session connect_* api message handling. Change-Id: If7fd125989c90240de12953658d10007b9eb4f07 Signed-off-by: Dave Wallace --- src/vnet/session/session.h | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'src/vnet/session/session.h') diff --git a/src/vnet/session/session.h b/src/vnet/session/session.h index 74d82a40..83addec2 100644 --- a/src/vnet/session/session.h +++ b/src/vnet/session/session.h @@ -38,6 +38,28 @@ typedef enum FIFO_EVENT_RPC, } fifo_event_type_t; +static inline const char * +fifo_event_type_str (fifo_event_type_t et) +{ + switch (et) + { + case FIFO_EVENT_APP_RX: + return "FIFO_EVENT_APP_RX"; + case FIFO_EVENT_APP_TX: + return "FIFO_EVENT_APP_TX"; + case FIFO_EVENT_TIMEOUT: + return "FIFO_EVENT_TIMEOUT"; + case FIFO_EVENT_DISCONNECT: + return "FIFO_EVENT_DISCONNECT"; + case FIFO_EVENT_BUILTIN_RX: + return "FIFO_EVENT_BUILTIN_RX"; + case FIFO_EVENT_RPC: + return "FIFO_EVENT_RPC"; + default: + return "UNKNOWN FIFO EVENT"; + } +} + #define foreach_session_input_error \ _(NO_SESSION, "No session drops") \ _(NO_LISTENER, "No listener for dst port drops") \ -- cgit 1.2.3-korg