From f39d03ad21d8120af847603d9b2ead71b8c4ba43 Mon Sep 17 00:00:00 2001 From: Max Date: Fri, 12 May 2017 17:00:30 +0200 Subject: Restructure SI2quater generation In preparation for extended SI2q messages: * add SI2q-specific accessor macro * add *_offset variables to gsm_bts struct * internalize memory check while generating rest octets - introduce budget concept (number of bits available in a given message) * internalize *arfcn_size() functions as they are not needed outside of si2q_num() anymore * change rest octets generation to work with gsm_bts struct directly * do not generate rest octets if no SI2q is necessary * adjust unit tests accordingly (cosmetic changes only to avoid regressions) Requires: I92e12e91605bdab9916a3f665705287572434f74 in libosmocore Change-Id: Ib554cf7ffc949a321571e1ae2ada1160e1b35fa6 Related: RT#8792 --- openbsc/src/libbsc/bsc_vty.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'openbsc/src/libbsc/bsc_vty.c') diff --git a/openbsc/src/libbsc/bsc_vty.c b/openbsc/src/libbsc/bsc_vty.c index 2794d85a1..2c7b6c0c5 100644 --- a/openbsc/src/libbsc/bsc_vty.c +++ b/openbsc/src/libbsc/bsc_vty.c @@ -2829,11 +2829,11 @@ DEFUN(cfg_bts_si2quater_neigh_add, cfg_bts_si2quater_neigh_add_cmd, e->prio_valid = true; } - if (si2q_num(bts) < 2) + if (si2q_num(bts) < 2) /* FIXME: use SI2Q_MAX_NUM */ return CMD_SUCCESS; - vty_out(vty, "Warning: not enough space in SI2quater for a given EARFCN " - "%u%s", arfcn, VTY_NEWLINE); + vty_out(vty, "Warning: not enough space in SI2quater (%u/%u used) for a given EARFCN %u%s", + bts->si2q_count, 2, arfcn, VTY_NEWLINE); /* FIXME: use SI2Q_MAX_NUM */ osmo_earfcn_del(e, arfcn); return CMD_WARNING; -- cgit v1.2.3