[MERGED] openbsc[master]: libbsc: add rsl_ericsson_imm_assign_cmd() which reply with a...

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Harald Welte gerrit-no-reply at lists.osmocom.org
Thu Mar 23 09:39:00 UTC 2017


Harald Welte has submitted this change and it was merged.

Change subject: libbsc: add rsl_ericsson_imm_assign_cmd() which reply with a confirmation message
......................................................................


libbsc: add rsl_ericsson_imm_assign_cmd() which reply with a confirmation message

ericsson can handle a reference at the end of a imm assign command which is used in
the confirm response. The confirm response is only sent if the trailer is present.

Change-Id: I88560291b5a3a3d7a0bac4d3c089b45f1f6b297f
---
M openbsc/include/openbsc/abis_rsl.h
M openbsc/src/libbsc/abis_rsl.c
2 files changed, 27 insertions(+), 1 deletion(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/openbsc/include/openbsc/abis_rsl.h b/openbsc/include/openbsc/abis_rsl.h
index 692b464..e61d4ea 100644
--- a/openbsc/include/openbsc/abis_rsl.h
+++ b/openbsc/include/openbsc/abis_rsl.h
@@ -57,6 +57,9 @@
 int rsl_establish_request(struct gsm_lchan *lchan, uint8_t link_id);
 int rsl_relase_request(struct gsm_lchan *lchan, uint8_t link_id);
 
+/* Ericcson vendor specific RSL extensions */
+int rsl_ericsson_imm_assign_cmd(struct gsm_bts *bts, uint32_t tlli, uint8_t len, uint8_t *val);
+
 /* Siemens vendor-specific RSL extensions */
 int rsl_siemens_mrpci(struct gsm_lchan *lchan, struct rsl_mrpci *mrpci);
 
diff --git a/openbsc/src/libbsc/abis_rsl.c b/openbsc/src/libbsc/abis_rsl.c
index 91cbd46..5ae707c 100644
--- a/openbsc/src/libbsc/abis_rsl.c
+++ b/openbsc/src/libbsc/abis_rsl.c
@@ -1048,7 +1048,7 @@
 }
 
 /* Chapter 8.5.6 */
-int rsl_imm_assign_cmd(struct gsm_bts *bts, uint8_t len, uint8_t *val)
+struct msgb *rsl_imm_assign_cmd_common(struct gsm_bts *bts, uint8_t len, uint8_t *val)
 {
 	struct msgb *msg = rsl_msgb_alloc();
 	struct abis_rsl_dchan_hdr *dh;
@@ -1071,6 +1071,29 @@
 	}
 
 	msg->dst = bts->c0->rsl_link;
+	return msg;
+}
+
+/* Chapter 8.5.6 */
+int rsl_imm_assign_cmd(struct gsm_bts *bts, uint8_t len, uint8_t *val)
+{
+	struct msgb *msg = rsl_imm_assign_cmd_common(bts, len, val);
+	if (!msg)
+		return 1;
+	return abis_rsl_sendmsg(msg);
+}
+
+/* Chapter 8.5.6 */
+int rsl_ericsson_imm_assign_cmd(struct gsm_bts *bts, uint32_t tlli, uint8_t len, uint8_t *val)
+{
+	struct msgb *msg = rsl_imm_assign_cmd_common(bts, len, val);
+	if (!msg)
+		return 1;
+
+	/* ericsson can handle a reference at the end of the message which is used in
+	 * the confirm message. The confirm message is only sent if the trailer is present */
+	msgb_put_u8(msg, RSL_IE_ERIC_MOBILE_ID);
+	msgb_put_u32(msg, tlli);
 
 	return abis_rsl_sendmsg(msg);
 }

-- 
To view, visit https://gerrit.osmocom.org/2040
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I88560291b5a3a3d7a0bac4d3c089b45f1f6b297f
Gerrit-PatchSet: 2
Gerrit-Project: openbsc
Gerrit-Branch: master
Gerrit-Owner: lynxis lazus <lynxis at fe80.eu>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder



More information about the gerrit-log mailing list