laforge submitted this change.

View Change

Approvals: laforge: Looks good to me, approved fixeria: Looks good to me, approved pespin: Looks good to me, but someone else must approve Jenkins Builder: Verified
abis_om2000: om2k_trx_s_done_onenter() does not send signal

the function om2k_trx_s_done_onenter() updates the administrative state
of the TRX oml MO but it does not notify the update to other entities
using S_NM_STATECHG

Change-Id: Iabf9f3a1a345c5d53d9a4d02fa2d6d13ddfd86ae
Related: OS#5634
---
M src/osmo-bsc/abis_om2000.c
1 file changed, 14 insertions(+), 2 deletions(-)

diff --git a/src/osmo-bsc/abis_om2000.c b/src/osmo-bsc/abis_om2000.c
index 14f027d..63b2a63 100644
--- a/src/osmo-bsc/abis_om2000.c
+++ b/src/osmo-bsc/abis_om2000.c
@@ -2226,11 +2226,23 @@
static void om2k_trx_s_done_onenter(struct osmo_fsm_inst *fi, uint32_t prev_state)
{
struct om2k_trx_fsm_priv *otfp = fi->priv;
+ struct nm_statechg_signal_data nsd;
+ struct gsm_bts_trx *trx = otfp->trx;
+
+ memset(&nsd, 0, sizeof(nsd));
+
+ nsd.bts = trx->bts;
+ nsd.obj = trx;
+ nsd.old_state = trx->mo.nm_state;
+ nsd.new_state = trx->mo.nm_state;
+ nsd.om2k_mo = &trx->rbs2000.trxc.om2k_mo.addr;

/* See e1_config:bts_isdn_sign_link() / OS#4914 */
- otfp->trx->mo.nm_state.administrative = NM_STATE_UNLOCKED;
+ nsd.new_state.administrative = NM_STATE_UNLOCKED;
+ trx->mo.nm_state.administrative = nsd.new_state.administrative;
+ osmo_signal_dispatch(SS_NM, S_NM_STATECHG, &nsd);

- abis_om2000_fsm_transc_becomes_enabled(otfp->trx);
+ abis_om2000_fsm_transc_becomes_enabled(trx);

if (fi->proc.parent)
osmo_fsm_inst_dispatch(fi->proc.parent, otfp->done_event, NULL);

To view, visit change 28916. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: Iabf9f3a1a345c5d53d9a4d02fa2d6d13ddfd86ae
Gerrit-Change-Number: 28916
Gerrit-PatchSet: 4
Gerrit-Owner: dexter <pmaier@sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy@sysmocom.de>
Gerrit-Reviewer: laforge <laforge@osmocom.org>
Gerrit-Reviewer: pespin <pespin@sysmocom.de>
Gerrit-MessageType: merged