[vty] Add option to disable RF on a given TRX.
- Make sure that on runtime the Radio Carrier can be
locked and unlocked. The vty code calls into the
Abis NM to lock/unlock the channel and the state is
stored there.
- Make sure that on start the Radio Carries remains
offline and we are not starting it. On start the
radio carrier is either locked or unlocked. This means
the RSL will not connect until the RF is unlocked. It
will connect then. To see RSL bringup failures one
needs to parse the RSL nack message.
- When the TRX is locked on startup the RSL link will
only be established after it will be unlocked.
diff --git a/openbsc/src/abis_nm.c b/openbsc/src/abis_nm.c
index 4d4cec0..b1fe97d 100755
--- a/openbsc/src/abis_nm.c
+++ b/openbsc/src/abis_nm.c
@@ -2699,6 +2699,19 @@
attr, attr_len);
}
+void gsm_trx_lock_rf(struct gsm_bts_trx *trx, int locked)
+{
+ int new_state = locked ? NM_STATE_LOCKED : NM_STATE_UNLOCKED;
+
+ trx->rf_locked = locked;
+ if (!trx->bts || !trx->bts->oml_link)
+ return;
+
+ abis_nm_chg_adm_state(trx->bts, NM_OC_RADIO_CARRIER,
+ trx->bts->bts_nr, trx->nr, 0xff,
+ new_state);
+}
+
static const char *ipacc_testres_names[] = {
[NM_IPACC_TESTRES_SUCCESS] = "SUCCESS",
[NM_IPACC_TESTRES_TIMEOUT] = "TIMEOUT",