This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
tnt gerrit-no-reply at lists.osmocom.orgtnt has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bsc/+/18135 ) Change subject: bts_nokia_site: Fake 12.21 OM objet state as "OK" when boot is done ...................................................................... bts_nokia_site: Fake 12.21 OM objet state as "OK" when boot is done Parts of Osmo-BSC want to see the NM state as valid ... Signed-off-by: Sylvain Munaut <tnt at 246tNt.com> Change-Id: I0db11819d23e40272c4aa6fd093365b9c13f7bcf --- M src/osmo-bsc/bts_nokia_site.c 1 file changed, 35 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/35/18135/1 diff --git a/src/osmo-bsc/bts_nokia_site.c b/src/osmo-bsc/bts_nokia_site.c index cde0afa..8047682 100644 --- a/src/osmo-bsc/bts_nokia_site.c +++ b/src/osmo-bsc/bts_nokia_site.c @@ -1436,6 +1436,39 @@ return 0; } +static void mo_ok(struct gsm_abis_mo *mo) +{ + mo->nm_state.operational = NM_OPSTATE_ENABLED; + mo->nm_state.administrative = NM_STATE_UNLOCKED; + mo->nm_state.availability = NM_AVSTATE_OK; +} + +static void nokia_abis_nm_fake_1221_ok(struct gsm_bts *bts) +{ + /* + * The Nokia BTS don't follow the 12.21 model and we don't have OM objects + * for the various elements. However some of the BSC code depends on seeing + * those object "up & running", so when the Nokia init is done, we fake + * a "good" state + */ + struct gsm_bts_trx *trx; + + mo_ok(&bts->mo); + mo_ok(&bts->site_mgr.mo); + + llist_for_each_entry(trx, &bts->trx_list, list) { + int i; + + mo_ok(&trx->mo); + mo_ok(&trx->bb_transc.mo); + + for (i = 0; i < ARRAY_SIZE(trx->ts); i++) { + struct gsm_bts_trx_ts *ts = &trx->ts[i]; + mo_ok(&ts->mo); + } + } +} + /* TODO: put in a separate file ? */ /* taken from abis_nm.c */ @@ -1633,6 +1666,8 @@ case NOKIA_MSG_CONF_COMPLETE: /* send ACK */ abis_nm_ack(bts, ref); + /* fake 12.21 OM */ + nokia_abis_nm_fake_1221_ok(bts); break; case NOKIA_MSG_BLOCK_CTRL_REQ: /* seems to be send when something goes wrong !? */ /* send ACK (do we have to send an ACK ?) */ -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/18135 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I0db11819d23e40272c4aa6fd093365b9c13f7bcf Gerrit-Change-Number: 18135 Gerrit-PatchSet: 1 Gerrit-Owner: tnt <tnt at 246tNt.com> Gerrit-MessageType: newchange -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20200508/6e7325ee/attachment.htm>