[PATCH] openbsc[master]: OM2000: Send ALTCRQ for SuperChannel after receiving IS Enab...

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/.

lynxis lazus gerrit-no-reply at lists.osmocom.org
Mon Mar 13 09:04:54 UTC 2017


Review at  https://gerrit.osmocom.org/2036

OM2000: Send ALTCRQ for SuperChannel after receiving IS Enable Req Ack

When the BTS is configured to use a SuperChannel and it is using a
unix domain socket based transport towards the L2TP daemon, then
we must instruct the L2TP daemon to instruct the SIU to change the Abis
Lower Transport Mode using the ALTCRQ / ALTCRP L2TP signalling.

Change-Id: I672bfaa09c42fbeb0c8459f24b2222b952de954b
---
M openbsc/include/openbsc/gsm_data_shared.h
M openbsc/src/libbsc/abis_om2000.c
M openbsc/src/libbsc/abis_om2000_vty.c
3 files changed, 32 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/openbsc refs/changes/36/2036/1

diff --git a/openbsc/include/openbsc/gsm_data_shared.h b/openbsc/include/openbsc/gsm_data_shared.h
index 7c469ee..acc5494 100644
--- a/openbsc/include/openbsc/gsm_data_shared.h
+++ b/openbsc/include/openbsc/gsm_data_shared.h
@@ -728,6 +728,7 @@
 				struct om2k_mo om2k_mo;
 				struct gsm_abis_mo mo;
 			} tf;
+			uint32_t use_superchannel:1;
 		} rbs2000;
 		struct {
 			uint8_t bts_type;
diff --git a/openbsc/src/libbsc/abis_om2000.c b/openbsc/src/libbsc/abis_om2000.c
index a594929..54e9b7c 100644
--- a/openbsc/src/libbsc/abis_om2000.c
+++ b/openbsc/src/libbsc/abis_om2000.c
@@ -1652,6 +1652,7 @@
 
 static void om2k_mo_st_wait_enable_accept(struct osmo_fsm_inst *fi, uint32_t event, void *data)
 {
+	struct om2k_mo_fsm_priv *omfp = fi->priv;
 	struct om2k_decoded_msg *omd = data;
 
 	switch (omd->msg_type) {
@@ -1659,6 +1660,9 @@
 		osmo_fsm_inst_state_chg(fi, OM2K_ST_ERROR, 0, 0);
 		break;
 	case OM2K_MSGT_ENABLE_REQ_ACK:
+		if (omfp->mo->addr.class == OM2K_MO_CLS_IS &&
+		    omfp->trx->bts->rbs2000.use_superchannel)
+			e1inp_ericsson_set_altc(omfp->trx->bts->oml_link->ts->line, 1);
 		osmo_fsm_inst_state_chg(fi, OM2K_ST_WAIT_ENABLE_RES,
 					OM2K_TIMEOUT, 0);
 	}
diff --git a/openbsc/src/libbsc/abis_om2000_vty.c b/openbsc/src/libbsc/abis_om2000_vty.c
index 060fb8b..a6bc4c7 100644
--- a/openbsc/src/libbsc/abis_om2000_vty.c
+++ b/openbsc/src/libbsc/abis_om2000_vty.c
@@ -417,6 +417,29 @@
 	return CMD_SUCCESS;
 }
 
+DEFUN(cfg_bts_alt_mode, cfg_bts_alt_mode_cmd,
+	"abis-lower-transport (single-timeslot|super-channel)",
+	"Configure thee Abis Lower Transport\n"
+	"Single Timeslot (classic Abis)\n"
+	"SuperChannel (Packet Abis)\n")
+{
+	struct gsm_bts *bts = vty->index;
+	struct con_group *cg;
+
+	if (bts->type != GSM_BTS_TYPE_RBS2000) {
+		vty_out(vty, "%% Command only works for RBS2000%s",
+			VTY_NEWLINE);
+		return CMD_WARNING;
+	}
+
+	if (!strcmp(argv[0], "super-channel"))
+		bts->rbs2000.use_superchannel = 1;
+	else
+		bts->rbs2000.use_superchannel = 0;
+
+	return CMD_SUCCESS;
+}
+
 DEFUN(cfg_bts_is_conn_list, cfg_bts_is_conn_list_cmd,
 	"is-connection-list (add|del) <0-2047> <0-2047> <0-255>",
 	"Interface Switch Connection List\n"
@@ -548,6 +571,9 @@
 			VTY_NEWLINE);
 		dump_con_group(vty, cgrp);
 	}
+	if (bts->rbs2000.use_superchannel)
+		vty_out(vty, "  abis-lower-transport super-channel%s",
+			VTY_NEWLINE);
 }
 
 int abis_om2k_vty_init(void)
@@ -575,6 +601,7 @@
 	install_element(OM2K_CON_GROUP_NODE, &cfg_om2k_con_path_conc_cmd);
 
 	install_element(BTS_NODE, &cfg_bts_is_conn_list_cmd);
+	install_element(BTS_NODE, &cfg_bts_alt_mode_cmd);
 	install_element(BTS_NODE, &cfg_om2k_con_group_cmd);
 	install_element(BTS_NODE, &del_om2k_con_group_cmd);
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I672bfaa09c42fbeb0c8459f24b2222b952de954b
Gerrit-PatchSet: 1
Gerrit-Project: openbsc
Gerrit-Branch: master
Gerrit-Owner: lynxis lazus <lynxis at fe80.eu>



More information about the gerrit-log mailing list