mgcp_client_fsm: Add FSM event names

The FSM lacks a proper definition of the FSM event names. This causes
problems when inspecting the FSM using the VTY.

- Add proper FSM Event names

Change-Id: Ic0990abea2e9fd92546e7b337b5ff3d6f0866321
Related: OS#2924
This commit is contained in:
Philipp Maier 2018-02-26 14:29:01 +01:00
parent 2924825bc6
commit d2e3a52230
1 changed files with 11 additions and 0 deletions

View File

@ -94,6 +94,16 @@ enum bsc_mgcp_fsm_evt {
EV_DLCX_RESP,
};
static const struct value_string fsm_mgcp_client_evt_names[] = {
OSMO_VALUE_STRING(EV_CRCX),
OSMO_VALUE_STRING(EV_CRCX_RESP),
OSMO_VALUE_STRING(EV_MDCX),
OSMO_VALUE_STRING(EV_MDCX_RESP),
OSMO_VALUE_STRING(EV_DLCX),
OSMO_VALUE_STRING(EV_DLCX_RESP),
{0, NULL}
};
static struct msgb *make_crcx_msg_bind(struct mgcp_ctx *mgcp_ctx)
{
struct mgcp_msg mgcp_msg;
@ -533,6 +543,7 @@ static struct osmo_fsm fsm_mgcp_client = {
.num_states = ARRAY_SIZE(fsm_mgcp_client_states),
.timer_cb = fsm_timeout_cb,
.cleanup = fsm_cleanup_cb,
.event_names = fsm_mgcp_client_evt_names,
};
/*! allocate FSM, and create a new connection on the MGW.