aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src/libbsc/bsc_vty.c
diff options
context:
space:
mode:
authorPau Espin Pedrol <pespin@sysmocom.de>2017-11-23 19:06:09 +0100
committerPau Espin Pedrol <pespin@sysmocom.de>2017-11-27 12:33:19 +0100
commit5d69fa52cf1e679e391519dd841da1579d640087 (patch)
tree20aa11ff19f5aa0a1a991eaad0af1d4183fe97b6 /openbsc/src/libbsc/bsc_vty.c
parent75042ff46a7e89ffb9a8897214c63e0bda378147 (diff)
vty: Add cmd to configure 3g Early Classmark Sending
In state prior to this patch, "3G Early Classmark Sending Restriction" bit in SI3 rest octets was always set to H, which is a sane default as the policy to send the information is then controlled by "Early Classmark Sending Control" bit in the same octet. However, it seems Quortus SoftCore can have some issues decoding the option, so let's add a vty cmd to be able to disable it for those having any issues. Related: SYS#4021 Change-Id: Ic1afe071038a3bb5871d7ff40f665c8644f801ec
Diffstat (limited to 'openbsc/src/libbsc/bsc_vty.c')
-rw-r--r--openbsc/src/libbsc/bsc_vty.c24
1 files changed, 23 insertions, 1 deletions
diff --git a/openbsc/src/libbsc/bsc_vty.c b/openbsc/src/libbsc/bsc_vty.c
index 60bea4f0c..3daa262c4 100644
--- a/openbsc/src/libbsc/bsc_vty.c
+++ b/openbsc/src/libbsc/bsc_vty.c
@@ -283,8 +283,11 @@ static void bts_dump_vty(struct vty *vty, struct gsm_bts *bts)
bts->si_common.chan_desc.bs_ag_blks_res, VTY_NEWLINE);
vty_out(vty, "System Information present: 0x%08x, static: 0x%08x%s",
bts->si_valid, bts->si_mode_static, VTY_NEWLINE);
- vty_out(vty, "Early Classmark Sending: %s%s",
+ vty_out(vty, "Early Classmark Sending: 2G %s, 3G %s%s%s",
bts->early_classmark_allowed ? "allowed" : "forbidden",
+ bts->early_classmark_allowed_3g ? "allowed" : "forbidden",
+ bts->early_classmark_allowed_3g && !bts->early_classmark_allowed ?
+ " (forbidden by 2G bit)" : "",
VTY_NEWLINE);
if (bts->pcu_sock_path)
vty_out(vty, "PCU Socket Path: %s%s", bts->pcu_sock_path, VTY_NEWLINE);
@@ -672,6 +675,8 @@ static void config_write_bts_single(struct vty *vty, struct gsm_bts *bts)
}
vty_out(vty, " early-classmark-sending %s%s",
bts->early_classmark_allowed ? "allowed" : "forbidden", VTY_NEWLINE);
+ vty_out(vty, " early-classmark-sending-3g %s%s",
+ bts->early_classmark_allowed_3g ? "allowed" : "forbidden", VTY_NEWLINE);
switch (bts->type) {
case GSM_BTS_TYPE_NANOBTS:
case GSM_BTS_TYPE_OSMOBTS:
@@ -2770,6 +2775,22 @@ DEFUN(cfg_bts_early_cm, cfg_bts_early_cm_cmd,
return CMD_SUCCESS;
}
+DEFUN(cfg_bts_early_cm_3g, cfg_bts_early_cm_3g_cmd,
+ "early-classmark-sending-3g (allowed|forbidden)",
+ "3G Early Classmark Sending\n"
+ "3G Early Classmark Sending is allowed\n"
+ "3G Early Classmark Sending is forbidden\n")
+{
+ struct gsm_bts *bts = vty->index;
+
+ if (!strcmp(argv[0], "allowed"))
+ bts->early_classmark_allowed_3g = true;
+ else
+ bts->early_classmark_allowed_3g = false;
+
+ return CMD_SUCCESS;
+}
+
DEFUN(cfg_bts_neigh_mode, cfg_bts_neigh_mode_cmd,
"neighbor-list mode (automatic|manual|manual-si5)",
"Neighbor List\n" "Mode of Neighbor List generation\n"
@@ -4291,6 +4312,7 @@ int bsc_vty_init(struct gsm_network *network)
install_element(BTS_NODE, &cfg_bts_si_mode_cmd);
install_element(BTS_NODE, &cfg_bts_si_static_cmd);
install_element(BTS_NODE, &cfg_bts_early_cm_cmd);
+ install_element(BTS_NODE, &cfg_bts_early_cm_3g_cmd);
install_element(BTS_NODE, &cfg_bts_neigh_mode_cmd);
install_element(BTS_NODE, &cfg_bts_neigh_cmd);
install_element(BTS_NODE, &cfg_bts_si5_neigh_cmd);