From defb6c95c14e95133891312b65436eef5964e0a3 Mon Sep 17 00:00:00 2001 From: Max Date: Mon, 15 May 2017 10:29:54 +0200 Subject: Get basic BTS attributes Request BTS attributes via OML on connection and parse the response: request/parse incoming response as sw-config. Note: only basic BTS-wide KV attributes wrapped in sw-config are supported for now. Change-Id: I589be51daca0cb9e1f3473b93e910e46b06e23ae Related: OS#1614 --- openbsc/src/libbsc/bsc_init.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'openbsc/src/libbsc/bsc_init.c') diff --git a/openbsc/src/libbsc/bsc_init.c b/openbsc/src/libbsc/bsc_init.c index 521fc891f..cda435044 100644 --- a/openbsc/src/libbsc/bsc_init.c +++ b/openbsc/src/libbsc/bsc_init.c @@ -310,6 +310,10 @@ static int inp_sig_cb(unsigned int subsys, unsigned int signal, struct input_signal_data *isd = signal_data; struct gsm_bts_trx *trx = isd->trx; int ts_no, lchan_no; + const uint8_t attr[] = { NM_ATT_SW_CONFIG, }; + + /* we should not request more attributes than we're ready to handle */ + OSMO_ASSERT(sizeof(attr) < MAX_BTS_ATTR); if (subsys != SS_L_INPUT) return -EINVAL; @@ -333,6 +337,8 @@ static int inp_sig_cb(unsigned int subsys, unsigned int signal, for (i = 0; i < ARRAY_SIZE(cur_trx->ts); i++) generate_ma_for_ts(&cur_trx->ts[i]); } + + abis_nm_get_attr(trx->bts, NM_OC_BTS, trx->bts->nr, trx->nr, 0xFF, attr, sizeof(attr)); } if (isd->link_type == E1INP_SIGN_RSL) bootstrap_rsl(trx); -- cgit v1.2.3