aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <holger@moiji-mobile.com>2015-09-21 16:52:03 +0200
committerHolger Hans Peter Freyther <holger@moiji-mobile.com>2015-09-21 16:52:03 +0200
commit2f79ae9b66dba654d77cb4ba76e8019ceb8556b4 (patch)
tree903fef859ab0ec7d9b2d409880069271d2b1fa9c
parentb492e86e4f75a4c09998d00930bf6c076293b3ed (diff)
ss7: Make the failure mode configurable
Try to make it clear that this is only for the IPA bridging mode and not a general setting.
-rw-r--r--src/vty_interface.c27
1 files changed, 27 insertions, 0 deletions
diff --git a/src/vty_interface.c b/src/vty_interface.c
index d5884f9..12288e1 100644
--- a/src/vty_interface.c
+++ b/src/vty_interface.c
@@ -343,6 +343,9 @@ static void write_application(struct vty *vty, struct ss7_application *app)
}
if (app->forward_only)
vty_out(vty, " forward-only%s", VTY_NEWLINE);
+
+ if (app->force_down)
+ vty_out(vty, " on-msc-down-force-down%s", VTY_NEWLINE);
}
static int config_write_app(struct vty *vty)
@@ -1113,6 +1116,28 @@ DEFUN(cfg_app_isup_pass, cfg_app_isup_pass_cmd,
return CMD_SUCCESS;
}
+DEFUN(cfg_app_fail, cfg_app_fail_cmd,
+ "on-msc-down-force-down",
+ "When the MSC connection is down force MTP linksets down\n")
+{
+ struct ss7_application *app = vty->index;
+
+ /* check if there is a MSC route? */
+ app->force_down = 1;
+ return CMD_SUCCESS;
+}
+
+DEFUN(cfg_app_no_fail, cfg_app_no_fail_cmd,
+ "no on-msc-down-force-down",
+ NO_STR "When the MSC connection is down force MTP linksets down\n")
+{
+ struct ss7_application *app = vty->index;
+
+ /* check if there is a MSC route? */
+ app->force_down = 0;
+ return CMD_SUCCESS;
+}
+
DEFUN(cfg_app_route, cfg_app_route_cmd,
"route linkset <0-100> msc <0-100>",
"Routing commands\n" "Source Linkset\n" "Linkset Nr\n"
@@ -1347,6 +1372,8 @@ void cell_vty_init(void)
install_defaults(APP_NODE);
install_element(APP_NODE, &cfg_app_type_cmd);
install_element(APP_NODE, &cfg_app_isup_pass_cmd);
+ install_element(APP_NODE, &cfg_app_fail_cmd);
+ install_element(APP_NODE, &cfg_app_no_fail_cmd);
install_element(APP_NODE, &cfg_app_route_cmd);
install_element(APP_NODE, &cfg_app_route_ls_cmd);
install_element(APP_NODE, &cfg_app_domain_name_cmd);