diff options
author | Alexander Chemeris <Alexander.Chemeris@gmail.com> | 2020-06-06 00:41:42 +0300 |
---|---|---|
committer | Kirill Zakharenko <earwin@gmail.com> | 2020-06-06 02:22:34 +0300 |
commit | 8dee5b7aacd3fea3186208e24c72592ede2b1382 (patch) | |
tree | 5879f3e77029d62cb6dacde8e4586004042a7d75 | |
parent | 731b6e1ae3ea8f01e34139478bb8e331da103db7 (diff) |
chan_alloc: Fix calculation of total available channels.
Change-Id: I989ebd7a10d223e4237dda705b0b68d5a91661d0
-rw-r--r-- | src/osmo-bsc/chan_alloc.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/osmo-bsc/chan_alloc.c b/src/osmo-bsc/chan_alloc.c index 8b6e28cb8..226984d56 100644 --- a/src/osmo-bsc/chan_alloc.c +++ b/src/osmo-bsc/chan_alloc.c @@ -58,6 +58,11 @@ void bts_chan_load(struct pchan_load *cl, const struct gsm_bts *bts) if (!nm_is_running(&ts->mo.nm_state)) continue; + /* skip timeslots which are not yet initialized or which + * have been de-initialized due to RSL link going down */ + if (ts->fi->state == TS_ST_NOT_INITIALIZED) + continue; + /* Dynamic timeslots have to be counted separately * when not in TCH/F or TCH/H mode because they don't * have an lchan's allocated to them. At the same time, |