aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src/abis_nm.c
diff options
context:
space:
mode:
authorlaforge <laflocal@goeller.de.gnumonks.org>2010-06-20 15:20:02 +0200
committerlaforge <laflocal@goeller.de.gnumonks.org>2010-06-20 15:20:02 +0200
commitf87ebe69d533079c5f4688262991e4ffb98b2560 (patch)
tree06a810e49b5144dffdf00f3bac9cd6caa1b683d6 /openbsc/src/abis_nm.c
parent09108bff9541d5dbaa20dfa6a0200706b34830e1 (diff)
[BSC] NM: Correct treatment of ARFCN_LIST for BS-11
For Siemens BS-11, the 'length' value of the ARFCN_LIST IE is interpreted in violation of the spec. The spec says it is a length in octets, while Siemens treats it as 'count of 16bit ARFCN values'.
Diffstat (limited to 'openbsc/src/abis_nm.c')
-rw-r--r--openbsc/src/abis_nm.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/openbsc/src/abis_nm.c b/openbsc/src/abis_nm.c
index 31302f1fd..63d9d9c3c 100644
--- a/openbsc/src/abis_nm.c
+++ b/openbsc/src/abis_nm.c
@@ -1990,7 +1990,11 @@ int abis_nm_set_channel_attr(struct gsm_bts_trx_ts *ts, u_int8_t chan_comb)
for (i = 0; i < ts->hopping.arfcns.data_len*8; i++) {
if (bitvec_get_bit_pos(&ts->hopping.arfcns, i)) {
msgb_put_u16(msg, i);
- *len += sizeof(uint16_t);
+ /* At least BS-11 wants a TLV16 here */
+ if (bts->type == GSM_BTS_TYPE_BS11)
+ *len += 1;
+ else
+ *len += sizeof(uint16_t);
}
}
}