aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src/bsc_init.c
diff options
context:
space:
mode:
authorlaforge <laflocal@goeller.de.gnumonks.org>2010-06-20 15:56:50 +0200
committerlaforge <laflocal@goeller.de.gnumonks.org>2010-06-20 15:56:50 +0200
commitabeb951426ebdcab5c99d5363fc381847ce64dd5 (patch)
tree2795b4e6ac5e47816b656edca867d329e7c2ef83 /openbsc/src/bsc_init.c
parentf87ebe69d533079c5f4688262991e4ffb98b2560 (diff)
[BSC] Fix off-by-one error in computing mobile allocation
Diffstat (limited to 'openbsc/src/bsc_init.c')
-rw-r--r--openbsc/src/bsc_init.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/openbsc/src/bsc_init.c b/openbsc/src/bsc_init.c
index 8e4aafd7d..787c0d5dd 100644
--- a/openbsc/src/bsc_init.c
+++ b/openbsc/src/bsc_init.c
@@ -967,13 +967,13 @@ static int generate_ma_for_ts(struct gsm_bts_trx_ts *ts)
for (i = 1; i < 1024; i++) {
if (!bitvec_get_bit_pos(cell_chan, i))
continue;
- n_chan++;
/* set the corresponding bit in the MA */
bitnum = (ts->hopping.ma_len * 8) - 1 - n_chan;
if (bitvec_get_bit_pos(ts_arfcn, i))
bitvec_set_bit_pos(ma, bitnum, 1);
else
bitvec_set_bit_pos(ma, bitnum, 0);
+ n_chan++;
}
/* ARFCN 0 is special: It is coded last in the bitmask */