|author||Pau Espin Pedrol <firstname.lastname@example.org>||2022-02-16 17:38:41 +0100|
|committer||Pau Espin Pedrol <email@example.com>||2022-02-16 19:05:04 +0100|
bts: Add explicit switch case for Cell Id SAI
This patch imposes no logical change in the code on itself, but makes sure people compiling osmo-bsc uses an old enough libosmocore implementing Cell Identifier SAI. This is important since adding the SAI ID (CELL_IDENT_SAI) displaced CELL_IDENT_WHOLE_GLOBAL_PS to a new number outside of the 3GPP range for cell IDS (4 bits, this way we garantee we won't have the same problem again). This means there was an ABI breakage (see Depends below). As a result, using an osmo-bsc compiled against an older libosmocore , and then using at runtime against a newer version of libosmocore, will most probably provoke some RIM features to not work properly, since libosmocore will handle CGI-PS cell ids sent by osmo-bsc as SAI ones, and most probably do wrong comparisons when matching (they only match up to LAI included). ABI break analysis: osmo-bsc uses CELL_IDENT_WHOLE_GLOBAL_PS in: * gsm0808_dec_cell_id_list2() -> this is called on stuff received from the network, so it's actually fine handling it correctly as CELL_IDENT_UTRAN_SAI instead of CGI_PS. * gsm0808_cell_id_list_add same_cell_id_list_entries gsm0808_enc_cell_id_list2 cell_id_to_cgi-> On old osmo-bsc, When CELL_IDENT_WHOLE_GLOBAL_PS is passed to be encoded as CGI, RAC byte is taken for encoding instead of 2nd CI byte. * gsm0808_cell_ids_match gsm0808_cell_id_u_match cell_id_to_cgi -> If CELL_IDENT_WHOLE_GLOBAL_PS as 0x11 (CELL_IDENT_UTRAN_SAI), 1 byte offset when comparing (1 byte of RAC is taken converting to CGI instead of the 2nd byte of CI). That means match would be wrong if 2nd byte of CI differs. Related: SYS#5838 Depends: libosmocore.git Change-Id Id25e563febdb7640174540136225f399515a0089 Change-Id: I70972efffefd57fd36332fab539683696c32f4a5
2 files changed, 2 insertions, 0 deletions
diff --git a/TODO-RELEASE b/TODO-RELEASE
index d0852fc9b..e0c43d985 100644
@@ -7,3 +7,4 @@
# If any interfaces have been added since the last public release: c:r:a + 1.
# If any interfaces have been removed or changed since the last public release: c:r:0.
#library what description / commit summary line
+libosmogsm >1.6.0 required due to CELL_IDENT_WHOLE_GLOBAL_PS/SAI ABI breakage
diff --git a/src/osmo-bsc/bts.c b/src/osmo-bsc/bts.c
index 1461585d2..c3e87b362 100644
@@ -524,6 +524,7 @@ bool gsm_bts_matches_cell_id(const struct gsm_bts *bts, const struct gsm0808_cel
+ case CELL_IDENT_SAI: