diff options
author | Neels Hofmeyr <neels@hofmeyr.de> | 2021-04-18 15:56:13 +0200 |
---|---|---|
committer | Neels Hofmeyr <neels@hofmeyr.de> | 2021-04-18 16:23:20 +0200 |
commit | 6be9e42a1d56d0c00c6e85920005f26dab3c6daf (patch) | |
tree | 80ef231bba3495a3e5ac80f264a51efd0ca740bf /src/osmo-bsc/system_information.c | |
parent | da6dae0daa0b33edaf715cdee88b6a9cd1761182 (diff) |
fix wrong ARFCNs in local-cell neighbor config
For neighbors configured without explicit ARFCN+BSIC ('neighbor bts N',
'neighbor lac-ci N M', ...), actually use the local neighbor cell's
ARFCN.
So far the code looked correct on first sight, but passed an unused part
of the struct neighbor union, always resulting in ARFCN 0.
Related: SYS#5367
Change-Id: Ifb54d9a91e9bca032c721f12c873c6216733e7b1
Diffstat (limited to 'src/osmo-bsc/system_information.c')
-rw-r--r-- | src/osmo-bsc/system_information.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/osmo-bsc/system_information.c b/src/osmo-bsc/system_information.c index 0dbf53c19..7ec613c41 100644 --- a/src/osmo-bsc/system_information.c +++ b/src/osmo-bsc/system_information.c @@ -673,12 +673,14 @@ static int generate_bcch_chan_list(uint8_t *chan_list, struct gsm_bts *bts, bitvec_set_bit_pos(bv, n->cell_id.ab.arfcn, 1); } else { struct gsm_bts *neigh_bts; - if (resolve_local_neighbor(&neigh_bts, bts, n) == 0) - bitvec_set_bit_pos(bv, n->cell_id.ab.arfcn, 1); - else + if (resolve_local_neighbor(&neigh_bts, bts, n)) { LOGP(DHO, LOGL_ERROR, "Neither local nor remote neighbor: BTS %u -> %s\n", bts->nr, neighbor_to_str_c(OTC_SELECT, n)); + continue; + } + if (neigh_bts->c0) + bitvec_set_bit_pos(bv, neigh_bts->c0->arfcn, 1); } } } |