diff options
author | Max <msuraev@sysmocom.de> | 2017-06-02 10:58:26 +0200 |
---|---|---|
committer | Max <msuraev@sysmocom.de> | 2017-06-15 11:43:10 +0000 |
commit | 9b97b007dfe96b8a74932ab101d5e341b5796f75 (patch) | |
tree | f193b2c76f615aa9ea8c6fb5b152e90720102594 /openbsc/include/openbsc/gsm_data_shared.h | |
parent | a60bb3dd28ce9e3720f8ee1b262893f3e233e2e6 (diff) |
Move SI-related defines
* move SI2quater related defines to shared header
* add define from OsmoBTS which checks for presence of a given SI
message in gsm_bts struct. Rename it to avoid conflicts with OsmoBTS
code and to match naming conventions of similar macros.
Change-Id: I11432c93c772d1ead6d45a7bb0f1d13d492c82f1
Related: OS#1660
Diffstat (limited to 'openbsc/include/openbsc/gsm_data_shared.h')
-rw-r--r-- | openbsc/include/openbsc/gsm_data_shared.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/openbsc/include/openbsc/gsm_data_shared.h b/openbsc/include/openbsc/gsm_data_shared.h index b72ed2d63..a507606e8 100644 --- a/openbsc/include/openbsc/gsm_data_shared.h +++ b/openbsc/include/openbsc/gsm_data_shared.h @@ -26,6 +26,12 @@ #include <openbsc/common_cs.h> +/* 16 is the max. number of SI2quater messages according to 3GPP TS 44.018: 4-bit index is used (2#1111 = 10#15) */ +#define SI2Q_MAX_NUM 16 +/* length in bits (for single SI2quater message) */ +#define SI2Q_MAX_LEN 160 +#define SI2Q_MIN_LEN 18 + struct osmo_bsc_data; struct osmo_bsc_sccp_con; @@ -486,6 +492,7 @@ struct gsm_bts_trx { }; #define GSM_BTS_SI2Q(bts) (struct gsm48_system_information_type_2quater *)((bts)->si_buf[SYSINFO_TYPE_2quater]) +#define GSM_BTS_HAS_SI(bts, i) ((bts)->si_valid & (1 << i)) #define GSM_BTS_SI(bts, i) (void *)((bts)->si_buf[i]) #define GSM_LCHAN_SI(lchan, i) (void *)((lchan)->si.buf[i]) |