aboutsummaryrefslogtreecommitdiffstats
path: root/src/vty_interface.c
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <zecke@selfish.org>2010-11-26 21:21:04 +0100
committerHolger Hans Peter Freyther <zecke@selfish.org>2010-11-26 21:21:04 +0100
commitb38b33b884d3ae4637d206c50e7f91a5c1b33857 (patch)
treeb6213885a0d79603e0a0eca542fb2beb11f15231 /src/vty_interface.c
parente976df1b5bf333a9af10559fbe1de3ab6537ca64 (diff)
mtp: Make the spare/ni configurable
Diffstat (limited to 'src/vty_interface.c')
-rw-r--r--src/vty_interface.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/vty_interface.c b/src/vty_interface.c
index f1ac86e..bc6c6e5 100644
--- a/src/vty_interface.c
+++ b/src/vty_interface.c
@@ -62,6 +62,8 @@ static int config_write_cell(struct vty *vty)
vty_out(vty, "cellmgr%s", VTY_NEWLINE);
vty_out(vty, " mtp dpc %d%s", bsc.dpc, VTY_NEWLINE);
vty_out(vty, " mtp opc %d%s", bsc.opc, VTY_NEWLINE);
+ vty_out(vty, " mtp ni %d%s", bsc.ni_ni, VTY_NEWLINE);
+ vty_out(vty, " mtp spare %d%s", bsc.ni_spare, VTY_NEWLINE);
vty_out(vty, " country-code %d%s", bsc.mcc, VTY_NEWLINE);
vty_out(vty, " network-code %d%s", bsc.mnc, VTY_NEWLINE);
vty_out(vty, " location-area-code %d%s", bsc.lac, VTY_NEWLINE);
@@ -101,6 +103,23 @@ DEFUN(cfg_net_opc, cfg_net_opc_cmd,
return CMD_SUCCESS;
}
+DEFUN(cfg_net_mtp_ni, cfg_net_mtp_ni_cmd,
+ "mtp ni NR",
+ "Set the MTP NI to be used.\n" "NR")
+{
+ bsc.ni_ni = atoi(argv[0]);
+ return CMD_SUCCESS;
+}
+
+DEFUN(cfg_net_mtp_spare, cfg_net_mtp_spare_cmd,
+ "mtp spare NR",
+ "Set the MTP Spare to be used.\n" "NR")
+{
+ bsc.ni_spare = atoi(argv[0]);
+ return CMD_SUCCESS;
+}
+
+
DEFUN(cfg_udp_dst_ip, cfg_udp_dst_ip_cmd,
"udp dest ip IP",
"Set the IP when UDP mode is supposed to be used.")
@@ -258,6 +277,8 @@ void cell_vty_init(void)
install_element(CELLMGR_NODE, &cfg_net_dpc_cmd);
install_element(CELLMGR_NODE, &cfg_net_opc_cmd);
+ install_element(CELLMGR_NODE, &cfg_net_mtp_ni_cmd);
+ install_element(CELLMGR_NODE, &cfg_net_mtp_spare_cmd);
install_element(CELLMGR_NODE, &cfg_udp_dst_ip_cmd);
install_element(CELLMGR_NODE, &cfg_udp_dst_port_cmd);
install_element(CELLMGR_NODE, &cfg_udp_src_port_cmd);