Harald Welte has submitted this change and it was merged.

Change subject: fix initialization of acc ramping

fix initialization of acc ramping

Remove a redundant call to acc_ramp_init() during bootstrap_bts().
ACC ramping state is already initialized during VTY config parsing,
and bootstrap_bts() accidentally disabled ACC ramping again even
if it was enabled in the configuration.

This bug was introduced in last-minute refactoring during
review of https://gerrit.osmocom.org/#/c/6324/ when the
acc_ramping_enabled flag was moved from struct gsm_bts to
the acc_ramp structure itself.

Also remove an acc_ramp_init() call in bootstrap_rsl().
It is no longer needed as it serves no purpose other than
initializing the bitmasks of barred ACCs. To ensure that
ACC ramping configuration provided to the BTS via system
information stays correct, we move the call to acc_ramp_start(),
which has the same effect on barred ACCs, further up.

Port of osmo-bsc commit f34fb4828249eab44b4515e0e54b3ee0491d0051
Fixes: 8469818e33ef81e9f707a0c4dd13d7b91ecf83f5
Related: OS#2591

Change-Id: I5834fd953e65b8453dee0a7751d5a4cae12be83a
M openbsc/src/libbsc/bsc_init.c
1 file changed, 4 insertions(+), 4 deletions(-)

  Pau Espin Pedrol: Looks good to me, but someone else must approve
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified

diff --git a/openbsc/src/libbsc/bsc_init.c b/openbsc/src/libbsc/bsc_init.c
index 9389c43..6147257 100644
--- a/openbsc/src/libbsc/bsc_init.c
+++ b/openbsc/src/libbsc/bsc_init.c
@@ -321,6 +321,9 @@
+       /* Configure ACC ramping before sending system information to BTS. */
+       if (acc_ramp_is_enabled(&trx->bts->acc_ramp))
+               acc_ramp_start(&trx->bts->acc_ramp);
        if (trx->bts->type == GSM_BTS_TYPE_NOKIA_SITE) {
@@ -331,9 +334,6 @@
        for (i = 0; i < ARRAY_SIZE(trx->ts); i++)
-       if (acc_ramp_is_enabled(&trx->bts->acc_ramp))
-               acc_ramp_start(&trx->bts->acc_ramp);
 /* Callback function to be called every time we receive a signal from INPUT */
@@ -521,7 +521,7 @@
        bts->chan_load_samples_idx = 0;
-       acc_ramp_init(&bts->acc_ramp, false, bts);
+       /* ACC ramping is initialized from vty/config */
        /* Initialize the BTS state */

To view, visit https://gerrit.osmocom.org/7692
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I5834fd953e65b8453dee0a7751d5a4cae12be83a
Gerrit-PatchSet: 3
Gerrit-Project: openbsc
Gerrit-Branch: master
Gerrit-Owner: Stefan Sperling <ssperl...@sysmocom.de>
Gerrit-Reviewer: Harald Welte <lafo...@gnumonks.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Pau Espin Pedrol <pes...@sysmocom.de>

Reply via email to