aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHarald Welte <laforge@gnumonks.org>2019-05-21 23:25:30 +0200
committerHarald Welte <laforge@gnumonks.org>2019-05-24 10:46:37 +0200
commitae46685a635b0d3801fbaab556ff79e4343ffac0 (patch)
treeda163cd89a4ebb0a15f933dd0785d42cc7946cc4
parent46b1c81c19471f2ba280cce96fbf758fcd79a981 (diff)
abis_rsl: Add support for extended CBCH to rsl_sms_cb_command()
Now that OsmoBTS understands about extended CBCH, let's at least update the BSC side function to allow for other code to generate such messages. Change-Id: I77a16b75ce311d63fb022475c8ff25fbbcee7f55
-rw-r--r--include/osmocom/bsc/abis_rsl.h2
-rw-r--r--src/osmo-bsc/abis_rsl.c4
-rw-r--r--src/osmo-bsc/bsc_vty.c2
3 files changed, 5 insertions, 3 deletions
diff --git a/include/osmocom/bsc/abis_rsl.h b/include/osmocom/bsc/abis_rsl.h
index 098d2e6..ec63090 100644
--- a/include/osmocom/bsc/abis_rsl.h
+++ b/include/osmocom/bsc/abis_rsl.h
@@ -90,7 +90,7 @@ int rsl_chan_ms_power_ctrl(struct gsm_lchan *lchan, unsigned int fpc, int dbm);
/* SMSCB functionality */
int rsl_sms_cb_command(struct gsm_bts *bts, uint8_t chan_number,
struct rsl_ie_cb_cmd_type cb_command,
- const uint8_t *data, int len);
+ bool use_extended_cbch, const uint8_t *data, int len);
/* some Nokia specific stuff */
int rsl_nokia_si_begin(struct gsm_bts_trx *trx);
diff --git a/src/osmo-bsc/abis_rsl.c b/src/osmo-bsc/abis_rsl.c
index bc07457..5a1c8ff 100644
--- a/src/osmo-bsc/abis_rsl.c
+++ b/src/osmo-bsc/abis_rsl.c
@@ -2172,7 +2172,7 @@ int abis_rsl_rcvmsg(struct msgb *msg)
int rsl_sms_cb_command(struct gsm_bts *bts, uint8_t chan_number,
struct rsl_ie_cb_cmd_type cb_command,
- const uint8_t *data, int len)
+ bool use_extended_cbch, const uint8_t *data, int len)
{
struct abis_rsl_dchan_hdr *dh;
struct msgb *cb_cmd;
@@ -2188,6 +2188,8 @@ int rsl_sms_cb_command(struct gsm_bts *bts, uint8_t chan_number,
msgb_tv_put(cb_cmd, RSL_IE_CB_CMD_TYPE, *(uint8_t*)&cb_command);
msgb_tlv_put(cb_cmd, RSL_IE_SMSCB_MSG, len, data);
+ if (use_extended_cbch)
+ msgb_tv_put(cb_cmd, RSL_IE_SMSCB_CHAN_INDICATOR, 0x01);
cb_cmd->dst = bts->c0->rsl_link;
diff --git a/src/osmo-bsc/bsc_vty.c b/src/osmo-bsc/bsc_vty.c
index dc97d12..88c845b 100644
--- a/src/osmo-bsc/bsc_vty.c
+++ b/src/osmo-bsc/bsc_vty.c
@@ -4582,7 +4582,7 @@ DEFUN(smscb_cmd, smscb_cmd_cmd,
return CMD_WARNING;
}
- rsl_sms_cb_command(bts, RSL_CHAN_SDCCH4_ACCH, cb_cmd, buf, rc);
+ rsl_sms_cb_command(bts, RSL_CHAN_SDCCH4_ACCH, cb_cmd, false, buf, rc);
return CMD_SUCCESS;
}