From b92a538d236ccffe97803279ecbaa242f8faa66a Mon Sep 17 00:00:00 2001 From: Holger Hans Peter Freyther Date: Fri, 21 Nov 2014 10:00:39 +0100 Subject: [PATCH] bts: Store the bcch_change_mark in the bts structure Store the BCCH change mark inside the BTS structure. This will allow us increment the number and re-generate the SIs. Related: SYS#739 --- openbsc/include/openbsc/gsm_data_shared.h | 3 ++- openbsc/src/libbsc/system_information.c | 3 +++ openbsc/src/libcommon/gsm_data_shared.c | 3 +++ 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/openbsc/include/openbsc/gsm_data_shared.h b/openbsc/include/openbsc/gsm_data_shared.h index 0704bd753..0c14232f5 100644 --- a/openbsc/include/openbsc/gsm_data_shared.h +++ b/openbsc/include/openbsc/gsm_data_shared.h @@ -686,8 +686,9 @@ struct gsm_bts { int num_trx; struct llist_head trx_list; - /* SI compatibility hacks */ + /* SI related items */ int force_combined_si; + int bcch_change_mark; #ifdef ROLE_BSC /* Abis NM queue */ diff --git a/openbsc/src/libbsc/system_information.c b/openbsc/src/libbsc/system_information.c index a3deefc73..97827f2d9 100644 --- a/openbsc/src/libbsc/system_information.c +++ b/openbsc/src/libbsc/system_information.c @@ -792,6 +792,9 @@ static int generate_si13(uint8_t *output, struct gsm_bts *bts) si13_default.no_pbcch.rac = bts->gprs.rac; si13_default.no_pbcch.net_ctrl_ord = bts->gprs.net_ctrl_ord; + /* Information about the other SIs */ + si13_default.bcch_change_mark = bts->bcch_change_mark; + ret = rest_octets_si13(si13->rest_octets, &si13_default); if (ret < 0) return ret; diff --git a/openbsc/src/libcommon/gsm_data_shared.c b/openbsc/src/libcommon/gsm_data_shared.c index 8d5d0f85d..8687a1047 100644 --- a/openbsc/src/libcommon/gsm_data_shared.c +++ b/openbsc/src/libcommon/gsm_data_shared.c @@ -276,6 +276,9 @@ struct gsm_bts *gsm_bts_alloc(void *ctx) bts->rach_ldavg_slots = -1; bts->paging.free_chans_need = -1; + /* si handling */ + bts->bcch_change_mark = 1; + return bts; }