summaryrefslogtreecommitdiffstats
path: root/vtysh
diff options
context:
space:
mode:
authorDavid Lamparter <equinox@opensourcerouting.org>2016-11-28 17:35:08 +0100
committerDavid Lamparter <equinox@opensourcerouting.org>2016-11-28 17:35:08 +0100
commitcdf76126497e0346e0cbb6fb27db2d24b3bc872e (patch)
tree43a505ff49a17f660e7f1a61fbb47ab1179d91ae /vtysh
parentzebra: add missing license headers to two files (diff)
parentisisd: fix loss of packets after circuit is brought up (diff)
downloadfrr-cdf76126497e0346e0cbb6fb27db2d24b3bc872e.tar.xz
frr-cdf76126497e0346e0cbb6fb27db2d24b3bc872e.zip
Merge remote-tracking branch 'cmaster-next' into cmaster-next-releng
Diffstat (limited to 'vtysh')
-rwxr-xr-xvtysh/extract.pl.in1
-rw-r--r--vtysh/vtysh.c12
-rw-r--r--vtysh/vtysh_config.c13
3 files changed, 25 insertions, 1 deletions
diff --git a/vtysh/extract.pl.in b/vtysh/extract.pl.in
index 565391b65..3e8593606 100755
--- a/vtysh/extract.pl.in
+++ b/vtysh/extract.pl.in
@@ -65,6 +65,7 @@ $ignore{'"address-family encapv6"'} = "ignore";
$ignore{'"address-family vpnv6"'} = "ignore";
$ignore{'"address-family vpnv6 unicast"'} = "ignore";
$ignore{'"exit-address-family"'} = "ignore";
+$ignore{'"exit-link-params"'} = "ignore";
$ignore{'"vnc defaults"'} = "ignore";
$ignore{'"vnc nve-group NAME"'} = "ignore";
$ignore{'"exit-vnc"'} = "ignore";
diff --git a/vtysh/vtysh.c b/vtysh/vtysh.c
index 17dd58a4a..6c00058c1 100644
--- a/vtysh/vtysh.c
+++ b/vtysh/vtysh.c
@@ -1976,6 +1976,17 @@ DEFUNSH (VTYSH_ZEBRA,
return CMD_SUCCESS;
}
+DEFUNSH (VTYSH_ZEBRA,
+ exit_link_params,
+ exit_link_params_cmd,
+ "exit-link-params",
+ "Exit from Link Params configuration node\n")
+{
+ if (vty->node == LINK_PARAMS_NODE)
+ vty->node = INTERFACE_NODE;
+ return CMD_SUCCESS;
+}
+
/* Memory */
DEFUN (vtysh_show_memory,
vtysh_show_memory_cmd,
@@ -3288,6 +3299,7 @@ vtysh_init_vty (void)
install_element (INTERFACE_NODE, &no_interface_desc_cmd);
install_element (INTERFACE_NODE, &vtysh_end_all_cmd);
install_element (INTERFACE_NODE, &vtysh_exit_interface_cmd);
+ install_element (LINK_PARAMS_NODE, &exit_link_params_cmd);
install_element (LINK_PARAMS_NODE, &vtysh_end_all_cmd);
install_element (LINK_PARAMS_NODE, &vtysh_exit_interface_cmd);
install_element (INTERFACE_NODE, &vtysh_quit_interface_cmd);
diff --git a/vtysh/vtysh_config.c b/vtysh/vtysh_config.c
index 4ec0e0028..e60e9c091 100644
--- a/vtysh/vtysh_config.c
+++ b/vtysh/vtysh_config.c
@@ -171,7 +171,18 @@ vtysh_config_parse_line (const char *line)
/* Store line to current configuration. */
if (config)
{
- if (config->index == RMAP_NODE ||
+ if (strncmp (line, " link-params", strlen (" link-params")) == 0)
+ {
+ config_add_line (config->line, line);
+ config->index = LINK_PARAMS_NODE;
+ }
+ else if (config->index == LINK_PARAMS_NODE &&
+ strncmp (line, " exit-link-params", strlen (" exit")) == 0)
+ {
+ config_add_line (config->line, line);
+ config->index = INTERFACE_NODE;
+ }
+ else if (config->index == RMAP_NODE ||
config->index == INTERFACE_NODE ||
config->index == NS_NODE ||
config->index == VTY_NODE)