lc15,oc2g,sysmo: Update GPRS NM object state at the right time

Change-Id: I2f331954835496504f1fafa572bd46ee83b03a63
This commit is contained in:
Pau Espin 2023-04-04 16:20:09 +02:00 committed by pespin
parent 91a1295a5a
commit f4505f6caf
3 changed files with 3 additions and 17 deletions

View File

@ -1884,14 +1884,8 @@ int bts_model_opstart(struct gsm_bts *bts, struct gsm_abis_mo *mo,
case NM_OC_GPRS_NSE:
case NM_OC_GPRS_CELL:
case NM_OC_GPRS_NSVC:
oml_mo_state_chg(mo, NM_OPSTATE_ENABLED, -1, -1);
oml_mo_state_chg(mo, NM_OPSTATE_ENABLED, NM_AVSTATE_OK, -1);
rc = oml_mo_opstart_ack(mo);
if (mo->obj_class == NM_OC_BTS) {
oml_mo_state_chg(&bts->mo, -1, NM_AVSTATE_OK, -1);
oml_mo_state_chg(&bts->gprs.nse.mo, -1, NM_AVSTATE_OK, -1);
oml_mo_state_chg(&bts->gprs.cell.mo, -1, NM_AVSTATE_OK, -1);
oml_mo_state_chg(&bts->gprs.nsvc[0].mo, -1, NM_AVSTATE_OK, -1);
}
break;
default:
rc = oml_mo_opstart_nack(mo, NM_NACK_OBJCLASS_NOTSUPP);

View File

@ -1873,10 +1873,6 @@ int bts_model_opstart(struct gsm_bts *bts, struct gsm_abis_mo *mo,
break;
case NM_OC_BTS:
rc = osmo_fsm_inst_dispatch(bts->mo.fi, NM_EV_OPSTART_ACK, NULL);
oml_mo_state_chg(&bts->mo, -1, NM_AVSTATE_OK, -1);
oml_mo_state_chg(&bts->gprs.nse.mo, -1, NM_AVSTATE_OK, -1);
oml_mo_state_chg(&bts->gprs.cell.mo, -1, NM_AVSTATE_OK, -1);
oml_mo_state_chg(&bts->gprs.nsvc[0].mo, -1, NM_AVSTATE_OK, -1);
break;
case NM_OC_RADIO_CARRIER:
trx = (struct gsm_bts_trx *) obj;
@ -1893,7 +1889,7 @@ int bts_model_opstart(struct gsm_bts *bts, struct gsm_abis_mo *mo,
case NM_OC_GPRS_NSE:
case NM_OC_GPRS_CELL:
case NM_OC_GPRS_NSVC:
oml_mo_state_chg(mo, NM_OPSTATE_ENABLED, -1, -1);
oml_mo_state_chg(mo, NM_OPSTATE_ENABLED, NM_AVSTATE_OK, -1);
rc = oml_mo_opstart_ack(mo);
break;
default:

View File

@ -1750,10 +1750,6 @@ int bts_model_opstart(struct gsm_bts *bts, struct gsm_abis_mo *mo,
break;
case NM_OC_BTS:
rc = osmo_fsm_inst_dispatch(bts->mo.fi, NM_EV_OPSTART_ACK, NULL);
oml_mo_state_chg(&bts->mo, -1, NM_AVSTATE_OK, -1);
oml_mo_state_chg(&bts->gprs.nse.mo, -1, NM_AVSTATE_OK, -1);
oml_mo_state_chg(&bts->gprs.cell.mo, -1, NM_AVSTATE_OK, -1);
oml_mo_state_chg(&bts->gprs.nsvc[0].mo, -1, NM_AVSTATE_OK, -1);
break;
case NM_OC_RADIO_CARRIER:
trx = (struct gsm_bts_trx *) obj;
@ -1770,7 +1766,7 @@ int bts_model_opstart(struct gsm_bts *bts, struct gsm_abis_mo *mo,
case NM_OC_GPRS_NSE:
case NM_OC_GPRS_CELL:
case NM_OC_GPRS_NSVC:
oml_mo_state_chg(mo, NM_OPSTATE_ENABLED, -1, -1);
oml_mo_state_chg(mo, NM_OPSTATE_ENABLED, NM_AVSTATE_OK, -1);
rc = oml_mo_opstart_ack(mo);
break;
default: