From 02f2056ccf7ed9f0ebfeaa526823b87a98e57105 Mon Sep 17 00:00:00 2001 From: Pau Espin Pedrol Date: Mon, 20 Jul 2020 16:21:54 +0200 Subject: rename files acc_ramp.* -> acc.c* With upcoming next commit, the file will contain far more code that simply ramping, so rename it to be more generic. Change-Id: I8c368ab87e264439dea4ccf556821a44664cdbb0 --- include/osmocom/bsc/Makefile.am | 2 +- include/osmocom/bsc/acc.h | 161 +++++++++++++++++ include/osmocom/bsc/acc_ramp.h | 161 ----------------- include/osmocom/bsc/gsm_data.h | 2 +- src/ipaccess/Makefile.am | 4 +- src/osmo-bsc/Makefile.am | 2 +- src/osmo-bsc/acc.c | 362 ++++++++++++++++++++++++++++++++++++++ src/osmo-bsc/acc_ramp.c | 362 -------------------------------------- src/osmo-bsc/bsc_vty.c | 2 +- src/osmo-bsc/system_information.c | 2 +- src/utils/Makefile.am | 4 +- tests/abis/Makefile.am | 2 +- tests/bsc/Makefile.am | 2 +- tests/gsm0408/Makefile.am | 2 +- tests/handover/Makefile.am | 2 +- tests/nanobts_omlattr/Makefile.am | 2 +- 16 files changed, 537 insertions(+), 537 deletions(-) create mode 100644 include/osmocom/bsc/acc.h delete mode 100644 include/osmocom/bsc/acc_ramp.h create mode 100644 src/osmo-bsc/acc.c delete mode 100644 src/osmo-bsc/acc_ramp.c diff --git a/include/osmocom/bsc/Makefile.am b/include/osmocom/bsc/Makefile.am index c2a82ce34..1ee96ed50 100644 --- a/include/osmocom/bsc/Makefile.am +++ b/include/osmocom/bsc/Makefile.am @@ -3,7 +3,7 @@ noinst_HEADERS = \ abis_nm.h \ abis_om2000.h \ abis_rsl.h \ - acc_ramp.h \ + acc.h \ arfcn_range_encode.h \ assignment_fsm.h \ bsc_rll.h \ diff --git a/include/osmocom/bsc/acc.h b/include/osmocom/bsc/acc.h new file mode 100644 index 000000000..31fc74fbd --- /dev/null +++ b/include/osmocom/bsc/acc.h @@ -0,0 +1,161 @@ +/* (C) 2018 by sysmocom s.f.m.c. GmbH + * + * Author: Stefan Sperling + * + * All Rights Reserved + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Affero General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see . + * + */ + +#pragma once + +#include +#include + +#include +#include + +/*! + * Access control class (ACC) ramping is used to slowly make the cell available to + * an increasing number of MS. This avoids overload at startup time in cases where + * a lot of MS would discover the new cell and try to connect to it all at once. + */ + +#define ACC_RAMP_STEP_SIZE_MIN 1 /* allow at most 1 new ACC per ramp step */ +#define ACC_RAMP_STEP_SIZE_DEFAULT ACC_RAMP_STEP_SIZE_MIN +#define ACC_RAMP_STEP_SIZE_MAX 10 /* allow all ACC in one step (effectively disables ramping) */ + +#define ACC_RAMP_STEP_INTERVAL_MIN 30 /* 30 seconds */ +#define ACC_RAMP_STEP_INTERVAL_MAX 600 /* 10 minutes */ + +/*! + * Data structure used to manage ACC ramping. Please avoid setting or reading fields + * in this structure directly. Use the accessor functions below instead. + */ +struct acc_ramp { + struct gsm_bts *bts; /*!< backpointer to BTS using this ACC ramp */ + + bool acc_ramping_enabled; /*!< whether ACC ramping is enabled */ + + /*! + * Bitmask which keeps track of access control classes that are currently denied + * access. The function acc_ramp_apply() uses this mask to modulate bits from + * octets 2 and 3 in RACH Control Parameters (see 3GPP 44.018 10.5.2.29). + * Ramping is only concerned with ACCs 0-9. While any of the bits 0-9 is set, + * the corresponding ACC is barred. + * ACCs 11-15 should always be allowed, and ACC 10 denies emergency calls for + * all ACCs from 0-9 inclusive; these ACCs are ignored in this implementation. + */ + uint16_t barred_accs; + + /*! + * This controls the maximum number of ACCs to allow per ramping step (1 - 10). + * The compile-time default value is ACC_RAMP_STEP_SIZE_DEFAULT. + * This value can be changed by VTY configuration. + * A value of ACC_RAMP_STEP_SIZE_MAX effectively disables ramping. + */ + unsigned int step_size; + + /*! + * Ramping step interval in seconds. + * This value depends on the current BTS channel load average, unless + * it has been overridden by VTY configuration. + */ + unsigned int step_interval_sec; + bool step_interval_is_fixed; + struct osmo_timer_list step_timer; +}; + +/*! + * Enable or disable ACC ramping. + * When enabled, ramping begins once acc_ramp_start() is called. + * When disabled, an ACC ramping process in progress will continue + * unless acc_ramp_abort() is called as well. + * \param[in] acc_ramp Pointer to acc_ramp structure. + */ +static inline void acc_ramp_set_enabled(struct acc_ramp *acc_ramp, bool enable) +{ + acc_ramp->acc_ramping_enabled = enable; +} + +/*! + * Return true if ACC ramping is currently enabled, else false. + * \param[in] acc_ramp Pointer to acc_ramp structure. + */ +static inline bool acc_ramp_is_enabled(struct acc_ramp *acc_ramp) +{ + return acc_ramp->acc_ramping_enabled; +} + +/*! + * Return the current ACC ramp step size. + * \param[in] acc_ramp Pointer to acc_ramp structure. + */ +static inline unsigned int acc_ramp_get_step_size(struct acc_ramp *acc_ramp) +{ + return acc_ramp->step_size; +} + +/*! + * Return the current ACC ramp step interval (in seconds) + * \param[in] acc_ramp Pointer to acc_ramp structure. + */ +static inline unsigned int acc_ramp_get_step_interval(struct acc_ramp *acc_ramp) +{ + return acc_ramp->step_interval_sec; +} + +/*! + * If the step interval is dynamic, return true, else return false. + * \param[in] acc_ramp Pointer to acc_ramp structure. + */ +static inline bool acc_ramp_step_interval_is_dynamic(struct acc_ramp *acc_ramp) +{ + return !(acc_ramp->step_interval_is_fixed); +} + +/*! + * Return bitmasks which correspond to access control classes that are currently + * denied access. Ramping is only concerned with those bits which control access + * for ACCs 0-9, and any of the other bits will always be set to zero in these masks, i.e. + * it is safe to OR these bitmasks with the corresponding fields in struct gsm48_rach_control. + * \param[in] acc_ramp Pointer to acc_ramp structure. + */ +static inline uint8_t acc_ramp_get_barred_t2(struct acc_ramp *acc_ramp) +{ + return ((acc_ramp->barred_accs >> 8) & 0x03); +}; +static inline uint8_t acc_ramp_get_barred_t3(struct acc_ramp *acc_ramp) +{ + return (acc_ramp->barred_accs & 0xff); +} + +/*! + * Potentially mark certain Access Control Classes (ACCs) as barred in accordance to ACC ramping. + * \param[in] rach_control RACH control parameters in which barred ACCs will be configured. + * \param[in] acc_ramp Pointer to acc_ramp structure. + */ +static inline void acc_ramp_apply(struct gsm48_rach_control *rach_control, struct acc_ramp *acc_ramp) +{ + rach_control->t2 |= acc_ramp_get_barred_t2(acc_ramp); + rach_control->t3 |= acc_ramp_get_barred_t3(acc_ramp); +} + +void acc_ramp_init(struct acc_ramp *acc_ramp, struct gsm_bts *bts); +int acc_ramp_set_step_size(struct acc_ramp *acc_ramp, unsigned int step_size); +int acc_ramp_set_step_interval(struct acc_ramp *acc_ramp, unsigned int step_interval); +void acc_ramp_set_step_interval_dynamic(struct acc_ramp *acc_ramp); +void acc_ramp_trigger(struct acc_ramp *acc_ramp); +void acc_ramp_abort(struct acc_ramp *acc_ramp); diff --git a/include/osmocom/bsc/acc_ramp.h b/include/osmocom/bsc/acc_ramp.h deleted file mode 100644 index 31fc74fbd..000000000 --- a/include/osmocom/bsc/acc_ramp.h +++ /dev/null @@ -1,161 +0,0 @@ -/* (C) 2018 by sysmocom s.f.m.c. GmbH - * - * Author: Stefan Sperling - * - * All Rights Reserved - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU Affero General Public License as published by - * the Free Software Foundation; either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Affero General Public License for more details. - * - * You should have received a copy of the GNU Affero General Public License - * along with this program. If not, see . - * - */ - -#pragma once - -#include -#include - -#include -#include - -/*! - * Access control class (ACC) ramping is used to slowly make the cell available to - * an increasing number of MS. This avoids overload at startup time in cases where - * a lot of MS would discover the new cell and try to connect to it all at once. - */ - -#define ACC_RAMP_STEP_SIZE_MIN 1 /* allow at most 1 new ACC per ramp step */ -#define ACC_RAMP_STEP_SIZE_DEFAULT ACC_RAMP_STEP_SIZE_MIN -#define ACC_RAMP_STEP_SIZE_MAX 10 /* allow all ACC in one step (effectively disables ramping) */ - -#define ACC_RAMP_STEP_INTERVAL_MIN 30 /* 30 seconds */ -#define ACC_RAMP_STEP_INTERVAL_MAX 600 /* 10 minutes */ - -/*! - * Data structure used to manage ACC ramping. Please avoid setting or reading fields - * in this structure directly. Use the accessor functions below instead. - */ -struct acc_ramp { - struct gsm_bts *bts; /*!< backpointer to BTS using this ACC ramp */ - - bool acc_ramping_enabled; /*!< whether ACC ramping is enabled */ - - /*! - * Bitmask which keeps track of access control classes that are currently denied - * access. The function acc_ramp_apply() uses this mask to modulate bits from - * octets 2 and 3 in RACH Control Parameters (see 3GPP 44.018 10.5.2.29). - * Ramping is only concerned with ACCs 0-9. While any of the bits 0-9 is set, - * the corresponding ACC is barred. - * ACCs 11-15 should always be allowed, and ACC 10 denies emergency calls for - * all ACCs from 0-9 inclusive; these ACCs are ignored in this implementation. - */ - uint16_t barred_accs; - - /*! - * This controls the maximum number of ACCs to allow per ramping step (1 - 10). - * The compile-time default value is ACC_RAMP_STEP_SIZE_DEFAULT. - * This value can be changed by VTY configuration. - * A value of ACC_RAMP_STEP_SIZE_MAX effectively disables ramping. - */ - unsigned int step_size; - - /*! - * Ramping step interval in seconds. - * This value depends on the current BTS channel load average, unless - * it has been overridden by VTY configuration. - */ - unsigned int step_interval_sec; - bool step_interval_is_fixed; - struct osmo_timer_list step_timer; -}; - -/*! - * Enable or disable ACC ramping. - * When enabled, ramping begins once acc_ramp_start() is called. - * When disabled, an ACC ramping process in progress will continue - * unless acc_ramp_abort() is called as well. - * \param[in] acc_ramp Pointer to acc_ramp structure. - */ -static inline void acc_ramp_set_enabled(struct acc_ramp *acc_ramp, bool enable) -{ - acc_ramp->acc_ramping_enabled = enable; -} - -/*! - * Return true if ACC ramping is currently enabled, else false. - * \param[in] acc_ramp Pointer to acc_ramp structure. - */ -static inline bool acc_ramp_is_enabled(struct acc_ramp *acc_ramp) -{ - return acc_ramp->acc_ramping_enabled; -} - -/*! - * Return the current ACC ramp step size. - * \param[in] acc_ramp Pointer to acc_ramp structure. - */ -static inline unsigned int acc_ramp_get_step_size(struct acc_ramp *acc_ramp) -{ - return acc_ramp->step_size; -} - -/*! - * Return the current ACC ramp step interval (in seconds) - * \param[in] acc_ramp Pointer to acc_ramp structure. - */ -static inline unsigned int acc_ramp_get_step_interval(struct acc_ramp *acc_ramp) -{ - return acc_ramp->step_interval_sec; -} - -/*! - * If the step interval is dynamic, return true, else return false. - * \param[in] acc_ramp Pointer to acc_ramp structure. - */ -static inline bool acc_ramp_step_interval_is_dynamic(struct acc_ramp *acc_ramp) -{ - return !(acc_ramp->step_interval_is_fixed); -} - -/*! - * Return bitmasks which correspond to access control classes that are currently - * denied access. Ramping is only concerned with those bits which control access - * for ACCs 0-9, and any of the other bits will always be set to zero in these masks, i.e. - * it is safe to OR these bitmasks with the corresponding fields in struct gsm48_rach_control. - * \param[in] acc_ramp Pointer to acc_ramp structure. - */ -static inline uint8_t acc_ramp_get_barred_t2(struct acc_ramp *acc_ramp) -{ - return ((acc_ramp->barred_accs >> 8) & 0x03); -}; -static inline uint8_t acc_ramp_get_barred_t3(struct acc_ramp *acc_ramp) -{ - return (acc_ramp->barred_accs & 0xff); -} - -/*! - * Potentially mark certain Access Control Classes (ACCs) as barred in accordance to ACC ramping. - * \param[in] rach_control RACH control parameters in which barred ACCs will be configured. - * \param[in] acc_ramp Pointer to acc_ramp structure. - */ -static inline void acc_ramp_apply(struct gsm48_rach_control *rach_control, struct acc_ramp *acc_ramp) -{ - rach_control->t2 |= acc_ramp_get_barred_t2(acc_ramp); - rach_control->t3 |= acc_ramp_get_barred_t3(acc_ramp); -} - -void acc_ramp_init(struct acc_ramp *acc_ramp, struct gsm_bts *bts); -int acc_ramp_set_step_size(struct acc_ramp *acc_ramp, unsigned int step_size); -int acc_ramp_set_step_interval(struct acc_ramp *acc_ramp, unsigned int step_interval); -void acc_ramp_set_step_interval_dynamic(struct acc_ramp *acc_ramp); -void acc_ramp_trigger(struct acc_ramp *acc_ramp); -void acc_ramp_abort(struct acc_ramp *acc_ramp); diff --git a/include/osmocom/bsc/gsm_data.h b/include/osmocom/bsc/gsm_data.h index a8b495f0f..cfed1f82c 100644 --- a/include/osmocom/bsc/gsm_data.h +++ b/include/osmocom/bsc/gsm_data.h @@ -29,7 +29,7 @@ #include #include #include -#include +#include #include #include diff --git a/src/ipaccess/Makefile.am b/src/ipaccess/Makefile.am index a11b2958b..717a6a187 100644 --- a/src/ipaccess/Makefile.am +++ b/src/ipaccess/Makefile.am @@ -49,7 +49,7 @@ ipaccess_config_LDADD = \ $(top_builddir)/src/osmo-bsc/bts.o \ $(top_builddir)/src/osmo-bsc/bts_trx.o \ $(top_builddir)/src/osmo-bsc/abis_nm.o \ - $(top_builddir)/src/osmo-bsc/acc_ramp.o \ + $(top_builddir)/src/osmo-bsc/acc.o \ $(top_builddir)/src/osmo-bsc/bts_ipaccess_nanobts.o \ $(top_builddir)/src/osmo-bsc/bts_ipaccess_nanobts_omlattr.o \ $(top_builddir)/src/osmo-bsc/gsm_data.o \ @@ -64,7 +64,7 @@ ipaccess_proxy_SOURCES = \ ipaccess_proxy_LDADD = \ $(top_builddir)/src/osmo-bsc/abis_nm.o \ - $(top_builddir)/src/osmo-bsc/acc_ramp.o \ + $(top_builddir)/src/osmo-bsc/acc.o \ $(top_builddir)/src/osmo-bsc/bts.o \ $(top_builddir)/src/osmo-bsc/bts_trx.o \ $(top_builddir)/src/osmo-bsc/gsm_data.o \ diff --git a/src/osmo-bsc/Makefile.am b/src/osmo-bsc/Makefile.am index 231707cd7..c19d01bf7 100644 --- a/src/osmo-bsc/Makefile.am +++ b/src/osmo-bsc/Makefile.am @@ -32,7 +32,7 @@ osmo_bsc_SOURCES = \ abis_om2000.c \ abis_om2000_vty.c \ abis_rsl.c \ - acc_ramp.c \ + acc.c \ arfcn_range_encode.c \ assignment_fsm.c \ bsc_ctrl_commands.c \ diff --git a/src/osmo-bsc/acc.c b/src/osmo-bsc/acc.c new file mode 100644 index 000000000..a1941e42e --- /dev/null +++ b/src/osmo-bsc/acc.c @@ -0,0 +1,362 @@ +/* (C) 2018 by sysmocom s.f.m.c. GmbH + * + * Author: Stefan Sperling + * + * All Rights Reserved + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Affero General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see . + * + */ + +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +/* + * Check if an ACC has been permanently barred for a BTS, + * e.g. with the 'rach access-control-class' VTY command. + */ +static bool acc_is_permanently_barred(struct gsm_bts *bts, unsigned int acc) +{ + OSMO_ASSERT(acc <= 9); + if (acc == 8 || acc == 9) + return (bts->si_common.rach_control.t2 & (1 << (acc - 8))); + return (bts->si_common.rach_control.t3 & (1 << (acc))); +} + +static void allow_one_acc(struct acc_ramp *acc_ramp, unsigned int acc) +{ + OSMO_ASSERT(acc <= 9); + if (acc_ramp->barred_accs & (1 << acc)) + LOG_BTS(acc_ramp->bts, DRSL, LOGL_NOTICE, + "ACC RAMP: allowing Access Control Class %u\n", acc); + acc_ramp->barred_accs &= ~(1 << acc); +} + +static void barr_one_acc(struct acc_ramp *acc_ramp, unsigned int acc) +{ + OSMO_ASSERT(acc <= 9); + if ((acc_ramp->barred_accs & (1 << acc)) == 0) + LOG_BTS(acc_ramp->bts, DRSL, LOGL_NOTICE, + "ACC RAMP: barring Access Control Class %u\n", acc); + acc_ramp->barred_accs |= (1 << acc); +} + +static void barr_all_accs(struct acc_ramp *acc_ramp) +{ + unsigned int acc; + for (acc = 0; acc < 10; acc++) { + if (!acc_is_permanently_barred(acc_ramp->bts, acc)) + barr_one_acc(acc_ramp, acc); + } +} + +static void allow_all_accs(struct acc_ramp *acc_ramp) +{ + unsigned int acc; + for (acc = 0; acc < 10; acc++) { + if (!acc_is_permanently_barred(acc_ramp->bts, acc)) + allow_one_acc(acc_ramp, acc); + } +} + +static unsigned int get_next_step_interval(struct acc_ramp *acc_ramp) +{ + struct gsm_bts *bts = acc_ramp->bts; + uint64_t load; + + if (acc_ramp->step_interval_is_fixed) + return acc_ramp->step_interval_sec; + + /* Scale the step interval to current channel load average. */ + load = (bts->chan_load_avg << 8); /* convert to fixed-point */ + acc_ramp->step_interval_sec = ((load * ACC_RAMP_STEP_INTERVAL_MAX) / 100) >> 8; + if (acc_ramp->step_interval_sec < ACC_RAMP_STEP_SIZE_MIN) + acc_ramp->step_interval_sec = ACC_RAMP_STEP_INTERVAL_MIN; + else if (acc_ramp->step_interval_sec > ACC_RAMP_STEP_INTERVAL_MAX) + acc_ramp->step_interval_sec = ACC_RAMP_STEP_INTERVAL_MAX; + + LOG_BTS(bts, DRSL, LOGL_DEBUG, + "ACC RAMP: step interval set to %u seconds based on %u%% channel load average\n", + acc_ramp->step_interval_sec, bts->chan_load_avg); + return acc_ramp->step_interval_sec; +} + +static void do_acc_ramping_step(void *data) +{ + struct acc_ramp *acc_ramp = data; + int i; + + /* Shortcut in case we only do one ramping step. */ + if (acc_ramp->step_size == ACC_RAMP_STEP_SIZE_MAX) { + allow_all_accs(acc_ramp); + gsm_bts_set_system_infos(acc_ramp->bts); + return; + } + + /* Allow 'step_size' ACCs, starting from ACC0. ACC9 will be allowed last. */ + for (i = 0; i < acc_ramp->step_size; i++) { + int idx = ffs(acc_ramp_get_barred_t3(acc_ramp)); + if (idx > 0) { + /* One of ACC0-ACC7 is still bared. */ + unsigned int acc = idx - 1; + if (!acc_is_permanently_barred(acc_ramp->bts, acc)) + allow_one_acc(acc_ramp, acc); + } else { + idx = ffs(acc_ramp_get_barred_t2(acc_ramp)); + if (idx == 1 || idx == 2) { + /* ACC8 or ACC9 is still barred. */ + unsigned int acc = idx - 1 + 8; + if (!acc_is_permanently_barred(acc_ramp->bts, acc)) + allow_one_acc(acc_ramp, acc); + } else { + /* All ACCs are now allowed. */ + break; + } + } + } + + gsm_bts_set_system_infos(acc_ramp->bts); + + /* If we have not allowed all ACCs yet, schedule another ramping step. */ + if (acc_ramp_get_barred_t2(acc_ramp) != 0x00 || + acc_ramp_get_barred_t3(acc_ramp) != 0x00) + osmo_timer_schedule(&acc_ramp->step_timer, get_next_step_interval(acc_ramp), 0); +} + +/* Implements osmo_signal_cbfn() -- trigger or abort ACC ramping upon changes RF lock state. */ +static int acc_ramp_nm_sig_cb(unsigned int subsys, unsigned int signal, void *handler_data, void *signal_data) +{ + struct nm_statechg_signal_data *nsd = signal_data; + struct acc_ramp *acc_ramp = handler_data; + struct gsm_bts_trx *trx = NULL; + bool trigger_ramping = false, abort_ramping = false; + + /* Handled signals map to an Administrative State Change ACK, or a State Changed Event Report. */ + if (signal != S_NM_STATECHG_ADM && signal != S_NM_STATECHG_OPER) + return 0; + + if (nsd->obj_class != NM_OC_RADIO_CARRIER) + return 0; + + trx = nsd->obj; + + LOG_TRX(trx, DRSL, LOGL_DEBUG, "ACC RAMP: administrative state %s -> %s\n", + get_value_string(abis_nm_adm_state_names, nsd->old_state->administrative), + get_value_string(abis_nm_adm_state_names, nsd->new_state->administrative)); + LOG_TRX(trx, DRSL, LOGL_DEBUG, "ACC RAMP: operational state %s -> %s\n", + abis_nm_opstate_name(nsd->old_state->operational), + abis_nm_opstate_name(nsd->new_state->operational)); + + /* We only care about state changes of the first TRX. */ + if (trx->nr != 0) + return 0; + + /* RSL must already be up. We cannot send RACH system information to the BTS otherwise. */ + if (trx->rsl_link == NULL) { + LOG_TRX(trx, DRSL, LOGL_DEBUG, + "ACC RAMP: ignoring state change because RSL link is down\n"); + return 0; + } + + /* Trigger or abort ACC ramping based on the new state of this TRX. */ + if (nsd->old_state->administrative != nsd->new_state->administrative) { + switch (nsd->new_state->administrative) { + case NM_STATE_UNLOCKED: + if (nsd->old_state->operational != nsd->new_state->operational) { + /* + * Administrative and operational state have both changed. + * Trigger ramping only if TRX 0 will be both enabled and unlocked. + */ + if (nsd->new_state->operational == NM_OPSTATE_ENABLED) + trigger_ramping = true; + else + LOG_TRX(trx, DRSL, LOGL_DEBUG, + "ACC RAMP: ignoring state change because TRX is " + "transitioning into operational state '%s'\n", + abis_nm_opstate_name(nsd->new_state->operational)); + } else { + /* + * Operational state has not changed. + * Trigger ramping only if TRX 0 is already usable. + */ + if (trx_is_usable(trx)) + trigger_ramping = true; + else + LOG_TRX(trx, DRSL, LOGL_DEBUG, "ACC RAMP: ignoring state change " + "because TRX is not usable\n"); + } + break; + case NM_STATE_LOCKED: + case NM_STATE_SHUTDOWN: + abort_ramping = true; + break; + case NM_STATE_NULL: + default: + LOG_TRX(trx, DRSL, LOGL_ERROR, "ACC RAMP: unrecognized administrative state '0x%x' " + "reported for TRX 0\n", nsd->new_state->administrative); + break; + } + } + if (nsd->old_state->operational != nsd->new_state->operational) { + switch (nsd->new_state->operational) { + case NM_OPSTATE_ENABLED: + if (nsd->old_state->administrative != nsd->new_state->administrative) { + /* + * Administrative and operational state have both changed. + * Trigger ramping only if TRX 0 will be both enabled and unlocked. + */ + if (nsd->new_state->administrative == NM_STATE_UNLOCKED) + trigger_ramping = true; + else + LOG_TRX(trx, DRSL, LOGL_DEBUG, "ACC RAMP: ignoring state change " + "because TRX is transitioning into administrative state '%s'\n", + get_value_string(abis_nm_adm_state_names, nsd->new_state->administrative)); + } else { + /* + * Administrative state has not changed. + * Trigger ramping only if TRX 0 is already unlocked. + */ + if (trx->mo.nm_state.administrative == NM_STATE_UNLOCKED) + trigger_ramping = true; + else + LOG_TRX(trx, DRSL, LOGL_DEBUG, "ACC RAMP: ignoring state change " + "because TRX is in administrative state '%s'\n", + get_value_string(abis_nm_adm_state_names, trx->mo.nm_state.administrative)); + } + break; + case NM_OPSTATE_DISABLED: + abort_ramping = true; + break; + case NM_OPSTATE_NULL: + default: + LOG_TRX(trx, DRSL, LOGL_ERROR, "ACC RAMP: unrecognized operational state '0x%x' " + "reported for TRX 0\n", nsd->new_state->administrative); + break; + } + } + + if (trigger_ramping) + acc_ramp_trigger(acc_ramp); + else if (abort_ramping) + acc_ramp_abort(acc_ramp); + + return 0; +} + +/*! + * Initialize an acc_ramp data structure. + * Storage for this structure must be provided by the caller. + * + * By default, ACC ramping is disabled and all ACCs are allowed. + * + * \param[in] acc_ramp Pointer to acc_ramp structure to be initialized. + * \param[in] bts BTS which uses this ACC ramp data structure. + */ +void acc_ramp_init(struct acc_ramp *acc_ramp, struct gsm_bts *bts) +{ + acc_ramp->bts = bts; + acc_ramp_set_enabled(acc_ramp, false); + acc_ramp->step_size = ACC_RAMP_STEP_SIZE_DEFAULT; + acc_ramp->step_interval_sec = ACC_RAMP_STEP_INTERVAL_MIN; + acc_ramp->step_interval_is_fixed = false; + allow_all_accs(acc_ramp); + osmo_timer_setup(&acc_ramp->step_timer, do_acc_ramping_step, acc_ramp); + osmo_signal_register_handler(SS_NM, acc_ramp_nm_sig_cb, acc_ramp); +} + +/*! + * Change the ramping step size which controls how many ACCs will be allowed per ramping step. + * Returns negative on error (step_size out of range), else zero. + * \param[in] acc_ramp Pointer to acc_ramp structure. + * \param[in] step_size The new step size value. + */ +int acc_ramp_set_step_size(struct acc_ramp *acc_ramp, unsigned int step_size) +{ + if (step_size < ACC_RAMP_STEP_SIZE_MIN || step_size > ACC_RAMP_STEP_SIZE_MAX) + return -ERANGE; + + acc_ramp->step_size = step_size; + LOG_BTS(acc_ramp->bts, DRSL, LOGL_DEBUG, "ACC RAMP: ramping step size set to %u\n", step_size); + return 0; +} + +/*! + * Change the ramping step interval to a fixed value. Unless this function is called, + * the interval is automatically scaled to the BTS channel load average. + * \param[in] acc_ramp Pointer to acc_ramp structure. + * \param[in] step_interval The new fixed step interval in seconds. + */ +int acc_ramp_set_step_interval(struct acc_ramp *acc_ramp, unsigned int step_interval) +{ + if (step_interval < ACC_RAMP_STEP_INTERVAL_MIN || step_interval > ACC_RAMP_STEP_INTERVAL_MAX) + return -ERANGE; + + acc_ramp->step_interval_sec = step_interval; + acc_ramp->step_interval_is_fixed = true; + LOG_BTS(acc_ramp->bts, DRSL, LOGL_DEBUG, "ACC RAMP: ramping step interval set to %u seconds\n", + step_interval); + return 0; +} + +/*! + * Clear a previously set fixed ramping step interval, so that the interval + * is again automatically scaled to the BTS channel load average. + * \param[in] acc_ramp Pointer to acc_ramp structure. + */ +void acc_ramp_set_step_interval_dynamic(struct acc_ramp *acc_ramp) +{ + acc_ramp->step_interval_is_fixed = false; + LOG_BTS(acc_ramp->bts, DRSL, LOGL_DEBUG, "ACC RAMP: ramping step interval set to 'dynamic'\n"); +} + +/*! + * Determine if ACC ramping should be started according to configuration, and + * begin the ramping process if the necessary conditions are present. + * Perform at least one ramping step to allow 'step_size' ACCs. + * If 'step_size' is ACC_RAMP_STEP_SIZE_MAX, or if ACC ramping is disabled, + * all ACCs will be allowed immediately. + * \param[in] acc_ramp Pointer to acc_ramp structure. + */ +void acc_ramp_trigger(struct acc_ramp *acc_ramp) +{ + /* Abort any previously running ramping process and allow all available ACCs. */ + acc_ramp_abort(acc_ramp); + + if (acc_ramp_is_enabled(acc_ramp)) { + /* Set all available ACCs to barred and start ramping up. */ + barr_all_accs(acc_ramp); + do_acc_ramping_step(acc_ramp); + } +} + +/*! + * Abort the ramping process and allow all available ACCs immediately. + * \param[in] acc_ramp Pointer to acc_ramp structure. + */ +void acc_ramp_abort(struct acc_ramp *acc_ramp) +{ + if (osmo_timer_pending(&acc_ramp->step_timer)) + osmo_timer_del(&acc_ramp->step_timer); + + allow_all_accs(acc_ramp); +} diff --git a/src/osmo-bsc/acc_ramp.c b/src/osmo-bsc/acc_ramp.c deleted file mode 100644 index 761ab093c..000000000 --- a/src/osmo-bsc/acc_ramp.c +++ /dev/null @@ -1,362 +0,0 @@ -/* (C) 2018 by sysmocom s.f.m.c. GmbH - * - * Author: Stefan Sperling - * - * All Rights Reserved - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU Affero General Public License as published by - * the Free Software Foundation; either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Affero General Public License for more details. - * - * You should have received a copy of the GNU Affero General Public License - * along with this program. If not, see . - * - */ - -#include -#include -#include - -#include -#include -#include -#include -#include -#include -#include - -/* - * Check if an ACC has been permanently barred for a BTS, - * e.g. with the 'rach access-control-class' VTY command. - */ -static bool acc_is_permanently_barred(struct gsm_bts *bts, unsigned int acc) -{ - OSMO_ASSERT(acc <= 9); - if (acc == 8 || acc == 9) - return (bts->si_common.rach_control.t2 & (1 << (acc - 8))); - return (bts->si_common.rach_control.t3 & (1 << (acc))); -} - -static void allow_one_acc(struct acc_ramp *acc_ramp, unsigned int acc) -{ - OSMO_ASSERT(acc <= 9); - if (acc_ramp->barred_accs & (1 << acc)) - LOG_BTS(acc_ramp->bts, DRSL, LOGL_NOTICE, - "ACC RAMP: allowing Access Control Class %u\n", acc); - acc_ramp->barred_accs &= ~(1 << acc); -} - -static void barr_one_acc(struct acc_ramp *acc_ramp, unsigned int acc) -{ - OSMO_ASSERT(acc <= 9); - if ((acc_ramp->barred_accs & (1 << acc)) == 0) - LOG_BTS(acc_ramp->bts, DRSL, LOGL_NOTICE, - "ACC RAMP: barring Access Control Class %u\n", acc); - acc_ramp->barred_accs |= (1 << acc); -} - -static void barr_all_accs(struct acc_ramp *acc_ramp) -{ - unsigned int acc; - for (acc = 0; acc < 10; acc++) { - if (!acc_is_permanently_barred(acc_ramp->bts, acc)) - barr_one_acc(acc_ramp, acc); - } -} - -static void allow_all_accs(struct acc_ramp *acc_ramp) -{ - unsigned int acc; - for (acc = 0; acc < 10; acc++) { - if (!acc_is_permanently_barred(acc_ramp->bts, acc)) - allow_one_acc(acc_ramp, acc); - } -} - -static unsigned int get_next_step_interval(struct acc_ramp *acc_ramp) -{ - struct gsm_bts *bts = acc_ramp->bts; - uint64_t load; - - if (acc_ramp->step_interval_is_fixed) - return acc_ramp->step_interval_sec; - - /* Scale the step interval to current channel load average. */ - load = (bts->chan_load_avg << 8); /* convert to fixed-point */ - acc_ramp->step_interval_sec = ((load * ACC_RAMP_STEP_INTERVAL_MAX) / 100) >> 8; - if (acc_ramp->step_interval_sec < ACC_RAMP_STEP_SIZE_MIN) - acc_ramp->step_interval_sec = ACC_RAMP_STEP_INTERVAL_MIN; - else if (acc_ramp->step_interval_sec > ACC_RAMP_STEP_INTERVAL_MAX) - acc_ramp->step_interval_sec = ACC_RAMP_STEP_INTERVAL_MAX; - - LOG_BTS(bts, DRSL, LOGL_DEBUG, - "ACC RAMP: step interval set to %u seconds based on %u%% channel load average\n", - acc_ramp->step_interval_sec, bts->chan_load_avg); - return acc_ramp->step_interval_sec; -} - -static void do_acc_ramping_step(void *data) -{ - struct acc_ramp *acc_ramp = data; - int i; - - /* Shortcut in case we only do one ramping step. */ - if (acc_ramp->step_size == ACC_RAMP_STEP_SIZE_MAX) { - allow_all_accs(acc_ramp); - gsm_bts_set_system_infos(acc_ramp->bts); - return; - } - - /* Allow 'step_size' ACCs, starting from ACC0. ACC9 will be allowed last. */ - for (i = 0; i < acc_ramp->step_size; i++) { - int idx = ffs(acc_ramp_get_barred_t3(acc_ramp)); - if (idx > 0) { - /* One of ACC0-ACC7 is still bared. */ - unsigned int acc = idx - 1; - if (!acc_is_permanently_barred(acc_ramp->bts, acc)) - allow_one_acc(acc_ramp, acc); - } else { - idx = ffs(acc_ramp_get_barred_t2(acc_ramp)); - if (idx == 1 || idx == 2) { - /* ACC8 or ACC9 is still barred. */ - unsigned int acc = idx - 1 + 8; - if (!acc_is_permanently_barred(acc_ramp->bts, acc)) - allow_one_acc(acc_ramp, acc); - } else { - /* All ACCs are now allowed. */ - break; - } - } - } - - gsm_bts_set_system_infos(acc_ramp->bts); - - /* If we have not allowed all ACCs yet, schedule another ramping step. */ - if (acc_ramp_get_barred_t2(acc_ramp) != 0x00 || - acc_ramp_get_barred_t3(acc_ramp) != 0x00) - osmo_timer_schedule(&acc_ramp->step_timer, get_next_step_interval(acc_ramp), 0); -} - -/* Implements osmo_signal_cbfn() -- trigger or abort ACC ramping upon changes RF lock state. */ -static int acc_ramp_nm_sig_cb(unsigned int subsys, unsigned int signal, void *handler_data, void *signal_data) -{ - struct nm_statechg_signal_data *nsd = signal_data; - struct acc_ramp *acc_ramp = handler_data; - struct gsm_bts_trx *trx = NULL; - bool trigger_ramping = false, abort_ramping = false; - - /* Handled signals map to an Administrative State Change ACK, or a State Changed Event Report. */ - if (signal != S_NM_STATECHG_ADM && signal != S_NM_STATECHG_OPER) - return 0; - - if (nsd->obj_class != NM_OC_RADIO_CARRIER) - return 0; - - trx = nsd->obj; - - LOG_TRX(trx, DRSL, LOGL_DEBUG, "ACC RAMP: administrative state %s -> %s\n", - get_value_string(abis_nm_adm_state_names, nsd->old_state->administrative), - get_value_string(abis_nm_adm_state_names, nsd->new_state->administrative)); - LOG_TRX(trx, DRSL, LOGL_DEBUG, "ACC RAMP: operational state %s -> %s\n", - abis_nm_opstate_name(nsd->old_state->operational), - abis_nm_opstate_name(nsd->new_state->operational)); - - /* We only care about state changes of the first TRX. */ - if (trx->nr != 0) - return 0; - - /* RSL must already be up. We cannot send RACH system information to the BTS otherwise. */ - if (trx->rsl_link == NULL) { - LOG_TRX(trx, DRSL, LOGL_DEBUG, - "ACC RAMP: ignoring state change because RSL link is down\n"); - return 0; - } - - /* Trigger or abort ACC ramping based on the new state of this TRX. */ - if (nsd->old_state->administrative != nsd->new_state->administrative) { - switch (nsd->new_state->administrative) { - case NM_STATE_UNLOCKED: - if (nsd->old_state->operational != nsd->new_state->operational) { - /* - * Administrative and operational state have both changed. - * Trigger ramping only if TRX 0 will be both enabled and unlocked. - */ - if (nsd->new_state->operational == NM_OPSTATE_ENABLED) - trigger_ramping = true; - else - LOG_TRX(trx, DRSL, LOGL_DEBUG, - "ACC RAMP: ignoring state change because TRX is " - "transitioning into operational state '%s'\n", - abis_nm_opstate_name(nsd->new_state->operational)); - } else { - /* - * Operational state has not changed. - * Trigger ramping only if TRX 0 is already usable. - */ - if (trx_is_usable(trx)) - trigger_ramping = true; - else - LOG_TRX(trx, DRSL, LOGL_DEBUG, "ACC RAMP: ignoring state change " - "because TRX is not usable\n"); - } - break; - case NM_STATE_LOCKED: - case NM_STATE_SHUTDOWN: - abort_ramping = true; - break; - case NM_STATE_NULL: - default: - LOG_TRX(trx, DRSL, LOGL_ERROR, "ACC RAMP: unrecognized administrative state '0x%x' " - "reported for TRX 0\n", nsd->new_state->administrative); - break; - } - } - if (nsd->old_state->operational != nsd->new_state->operational) { - switch (nsd->new_state->operational) { - case NM_OPSTATE_ENABLED: - if (nsd->old_state->administrative != nsd->new_state->administrative) { - /* - * Administrative and operational state have both changed. - * Trigger ramping only if TRX 0 will be both enabled and unlocked. - */ - if (nsd->new_state->administrative == NM_STATE_UNLOCKED) - trigger_ramping = true; - else - LOG_TRX(trx, DRSL, LOGL_DEBUG, "ACC RAMP: ignoring state change " - "because TRX is transitioning into administrative state '%s'\n", - get_value_string(abis_nm_adm_state_names, nsd->new_state->administrative)); - } else { - /* - * Administrative state has not changed. - * Trigger ramping only if TRX 0 is already unlocked. - */ - if (trx->mo.nm_state.administrative == NM_STATE_UNLOCKED) - trigger_ramping = true; - else - LOG_TRX(trx, DRSL, LOGL_DEBUG, "ACC RAMP: ignoring state change " - "because TRX is in administrative state '%s'\n", - get_value_string(abis_nm_adm_state_names, trx->mo.nm_state.administrative)); - } - break; - case NM_OPSTATE_DISABLED: - abort_ramping = true; - break; - case NM_OPSTATE_NULL: - default: - LOG_TRX(trx, DRSL, LOGL_ERROR, "ACC RAMP: unrecognized operational state '0x%x' " - "reported for TRX 0\n", nsd->new_state->administrative); - break; - } - } - - if (trigger_ramping) - acc_ramp_trigger(acc_ramp); - else if (abort_ramping) - acc_ramp_abort(acc_ramp); - - return 0; -} - -/*! - * Initialize an acc_ramp data structure. - * Storage for this structure must be provided by the caller. - * - * By default, ACC ramping is disabled and all ACCs are allowed. - * - * \param[in] acc_ramp Pointer to acc_ramp structure to be initialized. - * \param[in] bts BTS which uses this ACC ramp data structure. - */ -void acc_ramp_init(struct acc_ramp *acc_ramp, struct gsm_bts *bts) -{ - acc_ramp->bts = bts; - acc_ramp_set_enabled(acc_ramp, false); - acc_ramp->step_size = ACC_RAMP_STEP_SIZE_DEFAULT; - acc_ramp->step_interval_sec = ACC_RAMP_STEP_INTERVAL_MIN; - acc_ramp->step_interval_is_fixed = false; - allow_all_accs(acc_ramp); - osmo_timer_setup(&acc_ramp->step_timer, do_acc_ramping_step, acc_ramp); - osmo_signal_register_handler(SS_NM, acc_ramp_nm_sig_cb, acc_ramp); -} - -/*! - * Change the ramping step size which controls how many ACCs will be allowed per ramping step. - * Returns negative on error (step_size out of range), else zero. - * \param[in] acc_ramp Pointer to acc_ramp structure. - * \param[in] step_size The new step size value. - */ -int acc_ramp_set_step_size(struct acc_ramp *acc_ramp, unsigned int step_size) -{ - if (step_size < ACC_RAMP_STEP_SIZE_MIN || step_size > ACC_RAMP_STEP_SIZE_MAX) - return -ERANGE; - - acc_ramp->step_size = step_size; - LOG_BTS(acc_ramp->bts, DRSL, LOGL_DEBUG, "ACC RAMP: ramping step size set to %u\n", step_size); - return 0; -} - -/*! - * Change the ramping step interval to a fixed value. Unless this function is called, - * the interval is automatically scaled to the BTS channel load average. - * \param[in] acc_ramp Pointer to acc_ramp structure. - * \param[in] step_interval The new fixed step interval in seconds. - */ -int acc_ramp_set_step_interval(struct acc_ramp *acc_ramp, unsigned int step_interval) -{ - if (step_interval < ACC_RAMP_STEP_INTERVAL_MIN || step_interval > ACC_RAMP_STEP_INTERVAL_MAX) - return -ERANGE; - - acc_ramp->step_interval_sec = step_interval; - acc_ramp->step_interval_is_fixed = true; - LOG_BTS(acc_ramp->bts, DRSL, LOGL_DEBUG, "ACC RAMP: ramping step interval set to %u seconds\n", - step_interval); - return 0; -} - -/*! - * Clear a previously set fixed ramping step interval, so that the interval - * is again automatically scaled to the BTS channel load average. - * \param[in] acc_ramp Pointer to acc_ramp structure. - */ -void acc_ramp_set_step_interval_dynamic(struct acc_ramp *acc_ramp) -{ - acc_ramp->step_interval_is_fixed = false; - LOG_BTS(acc_ramp->bts, DRSL, LOGL_DEBUG, "ACC RAMP: ramping step interval set to 'dynamic'\n"); -} - -/*! - * Determine if ACC ramping should be started according to configuration, and - * begin the ramping process if the necessary conditions are present. - * Perform at least one ramping step to allow 'step_size' ACCs. - * If 'step_size' is ACC_RAMP_STEP_SIZE_MAX, or if ACC ramping is disabled, - * all ACCs will be allowed immediately. - * \param[in] acc_ramp Pointer to acc_ramp structure. - */ -void acc_ramp_trigger(struct acc_ramp *acc_ramp) -{ - /* Abort any previously running ramping process and allow all available ACCs. */ - acc_ramp_abort(acc_ramp); - - if (acc_ramp_is_enabled(acc_ramp)) { - /* Set all available ACCs to barred and start ramping up. */ - barr_all_accs(acc_ramp); - do_acc_ramping_step(acc_ramp); - } -} - -/*! - * Abort the ramping process and allow all available ACCs immediately. - * \param[in] acc_ramp Pointer to acc_ramp structure. - */ -void acc_ramp_abort(struct acc_ramp *acc_ramp) -{ - if (osmo_timer_pending(&acc_ramp->step_timer)) - osmo_timer_del(&acc_ramp->step_timer); - - allow_all_accs(acc_ramp); -} diff --git a/src/osmo-bsc/bsc_vty.c b/src/osmo-bsc/bsc_vty.c index 11e51bec7..9cc76730e 100644 --- a/src/osmo-bsc/bsc_vty.c +++ b/src/osmo-bsc/bsc_vty.c @@ -64,7 +64,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/src/osmo-bsc/system_information.c b/src/osmo-bsc/system_information.c index 13d0f4673..fe78e8e8c 100644 --- a/src/osmo-bsc/system_information.c +++ b/src/osmo-bsc/system_information.c @@ -39,7 +39,7 @@ #include #include #include -#include +#include #include #include diff --git a/src/utils/Makefile.am b/src/utils/Makefile.am index 683c227ef..fd03cb384 100644 --- a/src/utils/Makefile.am +++ b/src/utils/Makefile.am @@ -48,7 +48,7 @@ bs11_config_SOURCES = \ bs11_config_LDADD = \ $(top_builddir)/src/osmo-bsc/abis_nm.o \ - $(top_builddir)/src/osmo-bsc/acc_ramp.o \ + $(top_builddir)/src/osmo-bsc/acc.o \ $(top_builddir)/src/osmo-bsc/bts.o \ $(top_builddir)/src/osmo-bsc/bts_trx.o \ $(top_builddir)/src/osmo-bsc/bts_siemens_bs11.o \ @@ -121,7 +121,7 @@ meas_json_SOURCES = \ meas_json_LDADD = \ $(top_builddir)/src/osmo-bsc/abis_nm.o \ - $(top_builddir)/src/osmo-bsc/acc_ramp.o \ + $(top_builddir)/src/osmo-bsc/acc.o \ $(top_builddir)/src/osmo-bsc/bts.o \ $(top_builddir)/src/osmo-bsc/bts_trx.o \ $(top_builddir)/src/osmo-bsc/gsm_data.o \ diff --git a/tests/abis/Makefile.am b/tests/abis/Makefile.am index 031d689f5..a245b51c8 100644 --- a/tests/abis/Makefile.am +++ b/tests/abis/Makefile.am @@ -26,7 +26,7 @@ abis_test_SOURCES = \ abis_test_LDADD = \ $(top_builddir)/src/osmo-bsc/abis_nm.o \ - $(top_builddir)/src/osmo-bsc/acc_ramp.o \ + $(top_builddir)/src/osmo-bsc/acc.o \ $(top_builddir)/src/osmo-bsc/bts.o \ $(top_builddir)/src/osmo-bsc/bts_trx.o \ $(top_builddir)/src/osmo-bsc/gsm_data.o \ diff --git a/tests/bsc/Makefile.am b/tests/bsc/Makefile.am index 282f60333..468c0321e 100644 --- a/tests/bsc/Makefile.am +++ b/tests/bsc/Makefile.am @@ -34,7 +34,7 @@ bsc_test_SOURCES = \ bsc_test_LDADD = \ $(top_builddir)/src/osmo-bsc/abis_nm.o \ - $(top_builddir)/src/osmo-bsc/acc_ramp.o \ + $(top_builddir)/src/osmo-bsc/acc.o \ $(top_builddir)/src/osmo-bsc/arfcn_range_encode.o \ $(top_builddir)/src/osmo-bsc/osmo_bsc_filter.o \ $(top_builddir)/src/osmo-bsc/bsc_subscriber.o \ diff --git a/tests/gsm0408/Makefile.am b/tests/gsm0408/Makefile.am index 4e223925b..66e407259 100644 --- a/tests/gsm0408/Makefile.am +++ b/tests/gsm0408/Makefile.am @@ -24,7 +24,7 @@ gsm0408_test_SOURCES = \ gsm0408_test_LDADD = \ $(top_builddir)/src/osmo-bsc/abis_nm.o \ - $(top_builddir)/src/osmo-bsc/acc_ramp.o \ + $(top_builddir)/src/osmo-bsc/acc.o \ $(top_builddir)/src/osmo-bsc/gsm_04_08_rr.o \ $(top_builddir)/src/osmo-bsc/arfcn_range_encode.o \ $(top_builddir)/src/osmo-bsc/bts.o \ diff --git a/tests/handover/Makefile.am b/tests/handover/Makefile.am index 661b3d29c..87981d995 100644 --- a/tests/handover/Makefile.am +++ b/tests/handover/Makefile.am @@ -47,7 +47,7 @@ handover_test_LDADD = \ $(top_builddir)/src/osmo-bsc/abis_om2000.o \ $(top_builddir)/src/osmo-bsc/abis_om2000_vty.o \ $(top_builddir)/src/osmo-bsc/abis_rsl.o \ - $(top_builddir)/src/osmo-bsc/acc_ramp.o \ + $(top_builddir)/src/osmo-bsc/acc.o \ $(top_builddir)/src/osmo-bsc/arfcn_range_encode.o \ $(top_builddir)/src/osmo-bsc/assignment_fsm.o \ $(top_builddir)/src/osmo-bsc/bsc_ctrl_commands.o \ diff --git a/tests/nanobts_omlattr/Makefile.am b/tests/nanobts_omlattr/Makefile.am index 67d059f35..1cdcc50a1 100644 --- a/tests/nanobts_omlattr/Makefile.am +++ b/tests/nanobts_omlattr/Makefile.am @@ -24,7 +24,7 @@ nanobts_omlattr_test_SOURCES = \ nanobts_omlattr_test_LDADD = \ $(top_builddir)/src/osmo-bsc/abis_nm.o \ - $(top_builddir)/src/osmo-bsc/acc_ramp.o \ + $(top_builddir)/src/osmo-bsc/acc.o \ $(top_builddir)/src/osmo-bsc/bts_ipaccess_nanobts_omlattr.o \ $(top_builddir)/src/osmo-bsc/bts.o \ $(top_builddir)/src/osmo-bsc/bts_trx.o \ -- cgit v1.2.3