aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHarald Welte <laforge@gnumonks.org>2018-03-11 20:49:19 +0100
committerHarald Welte <laforge@gnumonks.org>2018-03-11 21:23:49 +0100
commitf72bdfaaa98b84d7b2b0fba977af70e2ac82018e (patch)
treef79edb178c5166ea28b68847dd7a67e1cd746dd3
parent02d1fe87f0fdf4d9e08cde9f727f00e17343c20c (diff)
cosmetic: Document some SI scheduling related function API
-rw-r--r--src/common/rsl.c17
-rw-r--r--src/common/sysinfo.c1
2 files changed, 17 insertions, 1 deletions
diff --git a/src/common/rsl.c b/src/common/rsl.c
index 47f59d8c..669a39b4 100644
--- a/src/common/rsl.c
+++ b/src/common/rsl.c
@@ -496,7 +496,12 @@ static int rsl_rx_sms_bcast_cmd(struct gsm_bts_trx *trx, struct msgb *msg)
TLVP_VAL(&tp, RSL_IE_SMSCB_MSG));
}
-/* 'buf' must be caller-allocated and hold at least len + 2 or sizeof(sysinfo_buf_t) bytes */
+/*! Prefix a given SACCH frame with a L2/LAPDm UI header and store it in given output buffer.
+ * \param[out] buf Output buffer, must be caller-allocated and hold at least len + 2 or sizeof(sysinfo_buf_t) bytes
+ * \param[out] valid pointer to bit-mask of 'valid' System information types
+ * \param[in] current input data (L3 without L2/L1 header)
+ * \param[in] osmo_si Sytstem Infrormation Type (SYSINFO_TYPE_*)
+ * \param[in] len length of \a current in octets */
static inline void lapdm_ui_prefix(uint8_t *buf, uint32_t *valid, const uint8_t *current, uint8_t osmo_si, uint16_t len)
{
/* We have to pre-fix with the two-byte LAPDM UI header */
@@ -514,11 +519,21 @@ static inline void lapdm_ui_prefix(uint8_t *buf, uint32_t *valid, const uint8_t
memcpy(buf + 2, current, len);
}
+/*! Prefix a given SACCH frame with a L2/LAPDm UI header and store it in given BTS SACCH buffer
+ * \param[out] bts BTS in whose System Information State we shall store
+ * \param[in] current input data (L3 without L2/L1 header)
+ * \param[in] osmo_si Sytstem Infrormation Type (SYSINFO_TYPE_*)
+ * \param[in] len length of \a current in octets */
static inline void lapdm_ui_prefix_bts(struct gsm_bts *bts, const uint8_t *current, uint8_t osmo_si, uint16_t len)
{
lapdm_ui_prefix(GSM_BTS_SI(bts, osmo_si), &bts->si_valid, current, osmo_si, len);
}
+/*! Prefix a given SACCH frame with a L2/LAPDm UI header and store it in given lchan SACCH buffer
+ * \param[out] lchan Logical Channel in whose System Information State we shall store
+ * \param[in] current input data (L3 without L2/L1 header)
+ * \param[in] osmo_si Sytstem Infrormation Type (SYSINFO_TYPE_*)
+ * \param[in] len length of \a current in octets */
static inline void lapdm_ui_prefix_lchan(struct gsm_lchan *lchan, const uint8_t *current, uint8_t osmo_si, uint16_t len)
{
lapdm_ui_prefix(GSM_LCHAN_SI(lchan, osmo_si), &lchan->si.valid, current, osmo_si, len);
diff --git a/src/common/sysinfo.c b/src/common/sysinfo.c
index 6f7a3874..35820277 100644
--- a/src/common/sysinfo.c
+++ b/src/common/sysinfo.c
@@ -160,6 +160,7 @@ uint8_t num_agch(struct gsm_bts_trx *trx, const char * arg)
return 1;
}
+/* obtain the next to-be transmitted dowlink SACCH frame (L2 hdr + L3); returns pointer to lchan->si buffer */
uint8_t *lchan_sacch_get(struct gsm_lchan *lchan)
{
uint32_t tmp;