diff options
author | Pau Espin Pedrol <pespin@sysmocom.de> | 2023-04-06 20:06:32 +0200 |
---|---|---|
committer | Pau Espin Pedrol <pespin@sysmocom.de> | 2023-04-11 11:16:21 +0200 |
commit | c3e059ce04b0654f7bcc79e16666708b69b04cdf (patch) | |
tree | b5e64f0234d5421b4060b256eefbba8782ec9dfa | |
parent | 36ef885a6c6df4259e220174ccdb2603d4bbf186 (diff) |
nm: Document current state of SW_ACT in TRX related objects
Change-Id: Ie24503b25b9c8042edae696d5b002933c73d00fb
-rw-r--r-- | src/common/bts.c | 11 | ||||
-rw-r--r-- | src/common/nm_bts_fsm.c | 5 |
2 files changed, 14 insertions, 2 deletions
diff --git a/src/common/bts.c b/src/common/bts.c index 0dd830a0..1154c6a2 100644 --- a/src/common/bts.c +++ b/src/common/bts.c @@ -414,10 +414,17 @@ int bts_link_estab(struct gsm_bts *bts) LOGP(DOML, LOGL_INFO, "Main link established, sending NM Status.\n"); - /* BTS SITE MGR becomes Offline (tx SW ACT Report), BTS, NSE, etc. is DEPENDENCY */ + /* BTS SITE MGR becomes Offline (tx SW ACT Report) and dispatches same + * event to its children objects (except TRX level and below, see comment + * below) + */ osmo_fsm_inst_dispatch(bts->site_mgr->mo.fi, NM_EV_SW_ACT, NULL); - /* All other objects start off-line until the BTS Model code says otherwise */ + /* TRX objects are SW_ACTed by the lower layers (bts_model) when they + * become available. Since that may happen before the OML link becomes + * established, we need to manually trigger tx of state reports to the BSC + * so it learns current state and can go on bringing them up. + */ for (i = 0; i < bts->num_trx; i++) { struct gsm_bts_trx *trx = gsm_bts_trx_num(bts, i); diff --git a/src/common/nm_bts_fsm.c b/src/common/nm_bts_fsm.c index 13a4727b..451530fa 100644 --- a/src/common/nm_bts_fsm.c +++ b/src/common/nm_bts_fsm.c @@ -93,6 +93,11 @@ static void st_op_disabled_notinstalled(struct osmo_fsm_inst *fi, uint32_t event } nm_bts_fsm_state_chg(fi, NM_BTS_ST_OP_DISABLED_OFFLINE); + + /* Avoid submitting NM_EV_SW_ACT to children NM objects + * (RCARRIER, BBTRANSC), the lower layers (bts_model) are in charge + * of submitting them once the TRX becomes available + */ return; default: OSMO_ASSERT(0); |