diff options
Diffstat (limited to 'bfdd/bfdd_cli.c')
| -rw-r--r-- | bfdd/bfdd_cli.c | 20 | 
1 files changed, 20 insertions, 0 deletions
diff --git a/bfdd/bfdd_cli.c b/bfdd/bfdd_cli.c index a1710ec127..016e63b192 100644 --- a/bfdd/bfdd_cli.c +++ b/bfdd/bfdd_cli.c @@ -754,6 +754,21 @@ void bfd_cli_show_passive(struct vty *vty, const struct lyd_node *dnode,  		yang_dnode_get_bool(dnode, NULL) ? "" : "no ");  } +DEFPY_YANG(bfd_peer_log_session_changes, bfd_peer_log_session_changes_cmd, +	   "[no] log-session-changes", +	   NO_STR +	   "Log Up/Down changes for the session\n") +{ +	nb_cli_enqueue_change(vty, "./log-session-changes", NB_OP_MODIFY, no ? "false" : "true"); +	return nb_cli_apply_changes(vty, NULL); +} + +void bfd_cli_show_log_session_changes(struct vty *vty, const struct lyd_node *dnode, +				      bool show_defaults) +{ +	vty_out(vty, "  %slog-session-changes\n", yang_dnode_get_bool(dnode, NULL) ? "" : "no "); +} +  DEFPY_YANG(  	bfd_peer_minimum_ttl, bfd_peer_minimum_ttl_cmd,  	"[no] minimum-ttl (1-254)$ttl", @@ -1063,6 +1078,9 @@ ALIAS_YANG(bfd_peer_passive, bfd_profile_passive_cmd,        NO_STR        "Don't attempt to start sessions\n") +ALIAS_YANG(bfd_peer_log_session_changes, bfd_profile_log_session_changes_cmd, +	   "[no] log-session-changes", NO_STR "Log Up/Down session changes in the profile\n") +  ALIAS_YANG(bfd_peer_minimum_ttl, bfd_profile_minimum_ttl_cmd,        "[no] minimum-ttl (1-254)$ttl",        NO_STR @@ -1329,6 +1347,7 @@ bfdd_cli_init(void)  	install_element(BFD_PEER_NODE, &bfd_peer_echo_receive_interval_cmd);  	install_element(BFD_PEER_NODE, &bfd_peer_profile_cmd);  	install_element(BFD_PEER_NODE, &bfd_peer_passive_cmd); +	install_element(BFD_PEER_NODE, &bfd_peer_log_session_changes_cmd);  	install_element(BFD_PEER_NODE, &bfd_peer_minimum_ttl_cmd);  	install_element(BFD_PEER_NODE, &no_bfd_peer_minimum_ttl_cmd); @@ -1350,6 +1369,7 @@ bfdd_cli_init(void)  	install_element(BFD_PROFILE_NODE, &bfd_profile_echo_transmit_interval_cmd);  	install_element(BFD_PROFILE_NODE, &bfd_profile_echo_receive_interval_cmd);  	install_element(BFD_PROFILE_NODE, &bfd_profile_passive_cmd); +	install_element(BFD_PROFILE_NODE, &bfd_profile_log_session_changes_cmd);  	install_element(BFD_PROFILE_NODE, &bfd_profile_minimum_ttl_cmd);  	install_element(BFD_PROFILE_NODE, &no_bfd_profile_minimum_ttl_cmd);  }  | 
