[PATCH] openbsc[master]: Modify SI 13 field to support 11 bit RACH

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

bhargava_abhyankar gerrit-no-reply at lists.osmocom.org
Thu Jul 14 11:03:45 UTC 2016


Hello Harald Welte, Jenkins Builder, Holger Freyther,

I'd like you to reexamine a change.  Please visit

    https://gerrit.osmocom.org/436

to look at the new patch set (#2).

Modify SI 13 field to support 11 bit RACH

System Information 13 field EGPRS PACKET CHANNEL REQUEST is
modified to support 11 bit RACH. Further VTY configuration is added
to enable/disable 11 bit RACH support in EGPRS. By default 11 bit
RACH support is disabled.

Change-Id: I51357bec936c28a26ab9ff5d59e0e30ca3363297
---
M openbsc/include/openbsc/gsm_data_shared.h
M openbsc/include/openbsc/rest_octets.h
M openbsc/src/libbsc/bsc_vty.c
M openbsc/src/libbsc/rest_octets.c
M openbsc/src/libbsc/system_information.c
5 files changed, 44 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.osmocom.org:29418/openbsc refs/changes/36/436/2

diff --git a/openbsc/include/openbsc/gsm_data_shared.h b/openbsc/include/openbsc/gsm_data_shared.h
index d3a61af..c369ddf 100644
--- a/openbsc/include/openbsc/gsm_data_shared.h
+++ b/openbsc/include/openbsc/gsm_data_shared.h
@@ -690,6 +690,7 @@
 
 	/* Not entirely sure how ip.access specific this is */
 	struct {
+		uint8_t supports_11bit_rach;
 		enum bts_gprs_mode mode;
 		struct {
 			struct gsm_abis_mo mo;
diff --git a/openbsc/include/openbsc/rest_octets.h b/openbsc/include/openbsc/rest_octets.h
index 91413b5..e6b3fc7 100644
--- a/openbsc/include/openbsc/rest_octets.h
+++ b/openbsc/include/openbsc/rest_octets.h
@@ -88,6 +88,7 @@
 	uint32_t t3192;	/* in milliseconds */
 	uint32_t drx_timer_max;/* in seconds */
 	uint32_t bs_cv_max;
+	uint8_t  supports_11bit_rach;
 
 	uint8_t ext_info_present;
 	struct {
diff --git a/openbsc/src/libbsc/bsc_vty.c b/openbsc/src/libbsc/bsc_vty.c
index b0e8764..d602145 100644
--- a/openbsc/src/libbsc/bsc_vty.c
+++ b/openbsc/src/libbsc/bsc_vty.c
@@ -448,6 +448,9 @@
 	if (bts->gprs.mode == BTS_GPRS_NONE)
 		return;
 
+	vty_out(vty, "  gprs 11bit_rach_support %u%s",
+		bts->gprs.supports_11bit_rach, VTY_NEWLINE);
+
 	vty_out(vty, "  gprs routing area %u%s", bts->gprs.rac,
 		VTY_NEWLINE);
 	vty_out(vty, "  gprs network-control-order nc%u%s",
@@ -2724,6 +2727,34 @@
 	return CMD_SUCCESS;
 }
 
+#define ELEVEN_BIT_RACH_STR "11 bit RACH options\n"
+
+DEFUN(cfg_bts_gprs_11bit_rach_support, cfg_bts_gprs_11bit_rach_support_cmd,
+	"gprs 11bit_rach_support (0|1)",
+	ELEVEN_BIT_RACH_STR
+	"Disable 11 bit RACH for EGPRS\n"
+	"Enable 11 bit RACH for EGPRS")
+{
+	struct gsm_bts *bts = vty->index;
+
+	bts->gprs.supports_11bit_rach = atoi(argv[0]);
+
+	if (bts->gprs.supports_11bit_rach > 1) {
+		vty_out(vty, "Error in RACH type%s", VTY_NEWLINE);
+		return CMD_WARNING;
+	}
+
+	if ((bts->gprs.mode == BTS_GPRS_NONE) &&
+		(bts->gprs.supports_11bit_rach == 1)) {
+		vty_out(vty, "Error:gprs mode is none and 11bit rach is"
+			" enabled%s", VTY_NEWLINE);
+		return CMD_WARNING;
+
+	}
+
+	return CMD_SUCCESS;
+}
+
 #define SI_TEXT		"System Information Messages\n"
 #define SI_TYPE_TEXT "(1|2|3|4|5|6|7|8|9|10|13|16|17|18|19|20|2bis|2ter|2quater|5bis|5ter)"
 #define SI_TYPE_HELP 	"System Information Type 1\n"	\
@@ -4085,6 +4116,7 @@
 	install_element(BTS_NODE, &cfg_bts_penalty_time_rsvd_cmd);
 	install_element(BTS_NODE, &cfg_bts_radio_link_timeout_cmd);
 	install_element(BTS_NODE, &cfg_bts_gprs_mode_cmd);
+	install_element(BTS_NODE, &cfg_bts_gprs_11bit_rach_support_cmd);
 	install_element(BTS_NODE, &cfg_bts_gprs_ns_timer_cmd);
 	install_element(BTS_NODE, &cfg_bts_gprs_rac_cmd);
 	install_element(BTS_NODE, &cfg_bts_gprs_net_ctrl_ord_cmd);
diff --git a/openbsc/src/libbsc/rest_octets.c b/openbsc/src/libbsc/rest_octets.c
index 065fb7b..ee345ff 100644
--- a/openbsc/src/libbsc/rest_octets.c
+++ b/openbsc/src/libbsc/rest_octets.c
@@ -649,8 +649,15 @@
 			bitvec_set_uint(bv, (1 + 5 + 3)-1, 6);
 			/* EGPRS supported in the cell */
 			bitvec_set_bit(bv, 1);
+
 			/* 1bit EGPRS PACKET CHANNEL REQUEST */
-			bitvec_set_bit(bv, gco->ext_info.use_egprs_p_ch_req);
+			if (gco->supports_11bit_rach == 0) {
+				bitvec_set_bit(bv,
+					gco->ext_info.use_egprs_p_ch_req);
+			} else {
+				bitvec_set_bit(bv, 0);
+			}
+
 			/* 4bit BEP PERIOD */
 			bitvec_set_uint(bv, gco->ext_info.bep_period, 4);
 		}
diff --git a/openbsc/src/libbsc/system_information.c b/openbsc/src/libbsc/system_information.c
index fd228e3..17c0ad9 100644
--- a/openbsc/src/libbsc/system_information.c
+++ b/openbsc/src/libbsc/system_information.c
@@ -957,6 +957,7 @@
 		.drx_timer_max	= 3,
 		.bs_cv_max	= 15,
 		.ext_info_present = 0,
+		.supports_11bit_rach = 0,
 		.ext_info = {
 			/* The values below are just guesses ! */
 			.egprs_supported = 0,
@@ -1004,6 +1005,7 @@
 
 	/* Information about the other SIs */
 	si13_default.bcch_change_mark = bts->bcch_change_mark;
+	si13_default.cell_opts.supports_11bit_rach = bts->gprs.supports_11bit_rach;
 
 	ret = rest_octets_si13(si13->rest_octets, &si13_default);
 	if (ret < 0)

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

Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I51357bec936c28a26ab9ff5d59e0e30ca3363297
Gerrit-PatchSet: 2
Gerrit-Project: openbsc
Gerrit-Branch: master
Gerrit-Owner: bhargava_abhyankar <Bhargava.Abhyankar at radisys.com>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Holger Freyther <holger at freyther.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: bhargava_abhyankar <Bhargava.Abhyankar at radisys.com>



More information about the gerrit-log mailing list