Browse Source

*: Fix duplicate commands from view/enable node consolidation

Paul Jakma 3 years ago
parent
commit
0f2f7a3fa5
11 changed files with 4 additions and 94 deletions
  1. 0 2
      bgpd/bgp_filter.c
  2. 0 18
      bgpd/bgp_mplsvpn.c
  3. 0 4
      bgpd/bgp_nexthop.c
  4. 0 4
      bgpd/bgp_route.c
  5. 0 14
      bgpd/bgp_vty.c
  6. 0 4
      isisd/isis_spf.c
  7. 0 2
      isisd/isis_te.c
  8. 4 6
      lib/vty.c
  9. 0 37
      ospf6d/ospf6d.c
  10. 0 2
      ospfd/ospf_ri.c
  11. 0 1
      zebra/debug.c

+ 0 - 2
bgpd/bgp_filter.c

@@ -691,8 +691,6 @@ bgp_filter_init (void)
 
   install_element (VIEW_NODE, &show_ip_as_path_access_list_cmd);
   install_element (VIEW_NODE, &show_ip_as_path_access_list_all_cmd);
-  install_element (ENABLE_NODE, &show_ip_as_path_access_list_cmd);
-  install_element (ENABLE_NODE, &show_ip_as_path_access_list_all_cmd);
 }
 
 void

+ 0 - 18
bgpd/bgp_mplsvpn.c

@@ -1062,22 +1062,4 @@ bgp_mplsvpn_init (void)
   install_element (VIEW_NODE, &show_bgp_ipv6_vpn_neighbor_advertised_routes_cmd);
   install_element (VIEW_NODE, &show_bgp_ipv6_vpn_rd_neighbor_advertised_routes_cmd);
   install_element (VIEW_NODE, &show_bgp_ipv6_vpn_rd_neighbor_routes_cmd);
-
-  install_element (ENABLE_NODE, &show_bgp_ipv4_vpn_cmd);
-  install_element (ENABLE_NODE, &show_bgp_ipv4_vpn_rd_cmd);
-  install_element (ENABLE_NODE, &show_bgp_ipv4_vpn_tags_cmd);
-  install_element (ENABLE_NODE, &show_bgp_ipv4_vpn_rd_tags_cmd);
-  install_element (ENABLE_NODE, &show_bgp_ipv4_vpn_neighbor_routes_cmd);
-  install_element (ENABLE_NODE, &show_bgp_ipv4_vpn_neighbor_advertised_routes_cmd);
-  install_element (ENABLE_NODE, &show_bgp_ipv4_vpn_rd_neighbor_advertised_routes_cmd);
-  install_element (ENABLE_NODE, &show_bgp_ipv4_vpn_rd_neighbor_routes_cmd);
-
-  install_element (ENABLE_NODE, &show_bgp_ipv6_vpn_cmd);
-  install_element (ENABLE_NODE, &show_bgp_ipv6_vpn_rd_cmd);
-  install_element (ENABLE_NODE, &show_bgp_ipv6_vpn_tags_cmd);
-  install_element (ENABLE_NODE, &show_bgp_ipv6_vpn_rd_tags_cmd);
-  install_element (ENABLE_NODE, &show_bgp_ipv6_vpn_neighbor_routes_cmd);
-  install_element (ENABLE_NODE, &show_bgp_ipv6_vpn_neighbor_advertised_routes_cmd);
-  install_element (ENABLE_NODE, &show_bgp_ipv6_vpn_rd_neighbor_advertised_routes_cmd);
-  install_element (ENABLE_NODE, &show_bgp_ipv6_vpn_rd_neighbor_routes_cmd);
 }

+ 0 - 4
bgpd/bgp_nexthop.c

@@ -1506,10 +1506,6 @@ bgp_scan_init (void)
   install_element (VIEW_NODE, &show_ip_bgp_nexthop_cmd);
   install_element (VIEW_NODE, &show_ip_bgp_nexthop_detail_cmd);
   install_element (RESTRICTED_NODE, &show_ip_bgp_scan_cmd);
-  install_element (ENABLE_NODE, &show_ip_bgp_scan_cmd);
-  install_element (ENABLE_NODE, &show_ip_bgp_nexthop_cmd);
-  install_element (ENABLE_NODE, &show_ip_bgp_nexthop_detail_cmd);
-  install_element (ENABLE_NODE, &show_ip_bgp_scan_detail_cmd);
 }
 
 void

+ 0 - 4
bgpd/bgp_route.c

@@ -16639,7 +16639,6 @@ bgp_route_init (void)
   install_element (RESTRICTED_NODE, &show_bgp_ipv6_community2_exact_cmd);
   install_element (RESTRICTED_NODE, &show_bgp_ipv6_community3_exact_cmd);
   install_element (RESTRICTED_NODE, &show_bgp_ipv6_community4_exact_cmd);
-  install_element (ENABLE_NODE, &show_bgp_ipv6_community_list_exact_cmd);
 
   install_element (VIEW_NODE, &show_bgp_ipv6_community_list_cmd);
   install_element (VIEW_NODE, &show_bgp_ipv6_community_list_exact_cmd);
@@ -16653,9 +16652,6 @@ bgp_route_init (void)
   install_element (VIEW_NODE, &show_bgp_view_rsclient_prefix_cmd);
   install_element (RESTRICTED_NODE, &show_bgp_view_rsclient_route_cmd);
   install_element (RESTRICTED_NODE, &show_bgp_view_rsclient_prefix_cmd);
-
-  install_element (VIEW_NODE, &show_bgp_view_rsclient_route_cmd);
-  install_element (VIEW_NODE, &show_bgp_view_rsclient_prefix_cmd);
 }
 
 void

+ 0 - 14
bgpd/bgp_vty.c

@@ -11057,8 +11057,6 @@ bgp_vty_init (void)
   install_element (VIEW_NODE, &show_bgp_instance_ipv6_neighbors_cmd);
   install_element (VIEW_NODE, &show_bgp_instance_ipv6_neighbors_peer_cmd);
   install_element (RESTRICTED_NODE, &show_bgp_instance_ipv6_neighbors_peer_cmd);
-  install_element (VIEW_NODE, &show_bgp_instance_ipv6_neighbors_cmd);
-  install_element (VIEW_NODE, &show_bgp_instance_ipv6_neighbors_peer_cmd);
 
   /* "show ip bgp rsclient" commands. */
   install_element (VIEW_NODE, &show_bgp_instance_ipv4_safi_rsclient_summary_cmd);
@@ -11071,8 +11069,6 @@ bgp_vty_init (void)
   install_element (RESTRICTED_NODE, &show_bgp_rsclient_summary_cmd);
   install_element (RESTRICTED_NODE, &show_bgp_instance_rsclient_summary_cmd);
 
-  install_element (VIEW_NODE, &show_bgp_rsclient_summary_cmd);
-  install_element (VIEW_NODE, &show_bgp_instance_rsclient_summary_cmd);
   install_element (VIEW_NODE, &show_bgp_ipv6_rsclient_summary_cmd);
   install_element (VIEW_NODE, &show_bgp_instance_ipv6_rsclient_summary_cmd);
   install_element (VIEW_NODE, &show_bgp_instance_ipv6_safi_rsclient_summary_cmd);
@@ -11125,9 +11121,6 @@ bgp_vty_init (void)
   install_element (VIEW_NODE, &show_bgp_views_cmd);
   install_element (RESTRICTED_NODE, &show_bgp_views_cmd);
   
-  /* "show bgp views" commands. */
-  install_element (VIEW_NODE, &show_bgp_views_cmd);
-
   /* non afi/safi forms of commands */
   install_element (VIEW_NODE, &show_ip_bgp_summary_cmd);
   install_element (VIEW_NODE, &show_ip_bgp_instance_summary_cmd);
@@ -11161,8 +11154,6 @@ bgp_vty_init (void)
   install_element (VIEW_NODE, &show_bgp_ipv6_neighbors_cmd);
   install_element (VIEW_NODE, &show_bgp_ipv6_neighbors_peer_cmd);
   install_element (RESTRICTED_NODE, &show_bgp_ipv6_neighbors_peer_cmd);
-  install_element (VIEW_NODE, &show_bgp_ipv6_neighbors_cmd);
-  install_element (VIEW_NODE, &show_bgp_ipv6_neighbors_peer_cmd);
   install_element (VIEW_NODE, &show_ipv6_bgp_summary_cmd);
   install_element (VIEW_NODE, &show_ipv6_mbgp_summary_cmd);
   install_element (VIEW_NODE, &show_ip_bgp_rsclient_summary_cmd);
@@ -11173,7 +11164,6 @@ bgp_vty_init (void)
   install_element (RESTRICTED_NODE, &show_ip_bgp_instance_rsclient_summary_cmd);
   install_element (RESTRICTED_NODE, &show_ip_bgp_ipv4_rsclient_summary_cmd);
   install_element (RESTRICTED_NODE, &show_ip_bgp_instance_ipv4_rsclient_summary_cmd);
-  install_element (ENABLE_NODE, &show_ip_bgp_rsclient_summary_cmd);
   install_element (VIEW_NODE, &show_ip_bgp_paths_cmd);
   install_element (VIEW_NODE, &show_ip_bgp_ipv4_paths_cmd);
   /* Community-list. */
@@ -12033,8 +12023,6 @@ community_list_vty (void)
   install_element (CONFIG_NODE, &no_ip_community_list_name_expanded_cmd);
   install_element (VIEW_NODE, &show_ip_community_list_cmd);
   install_element (VIEW_NODE, &show_ip_community_list_arg_cmd);
-  install_element (ENABLE_NODE, &show_ip_community_list_cmd);
-  install_element (ENABLE_NODE, &show_ip_community_list_arg_cmd);
 
   /* Extcommunity-list.  */
   install_element (CONFIG_NODE, &ip_extcommunity_list_standard_cmd);
@@ -12053,6 +12041,4 @@ community_list_vty (void)
   install_element (CONFIG_NODE, &no_ip_extcommunity_list_name_expanded_cmd);
   install_element (VIEW_NODE, &show_ip_extcommunity_list_cmd);
   install_element (VIEW_NODE, &show_ip_extcommunity_list_arg_cmd);
-  install_element (ENABLE_NODE, &show_ip_extcommunity_list_cmd);
-  install_element (ENABLE_NODE, &show_ip_extcommunity_list_arg_cmd);
 }

+ 0 - 4
isisd/isis_spf.c

@@ -1692,8 +1692,4 @@ isis_spf_cmds_init ()
   install_element (VIEW_NODE, &show_isis_topology_cmd);
   install_element (VIEW_NODE, &show_isis_topology_l1_cmd);
   install_element (VIEW_NODE, &show_isis_topology_l2_cmd);
-
-  install_element (ENABLE_NODE, &show_isis_topology_cmd);
-  install_element (ENABLE_NODE, &show_isis_topology_l1_cmd);
-  install_element (ENABLE_NODE, &show_isis_topology_l2_cmd);
 }

+ 0 - 2
isisd/isis_te.c

@@ -1358,8 +1358,6 @@ isis_mpls_te_init (void)
   /* Register new VTY commands */
   install_element (VIEW_NODE, &show_isis_mpls_te_router_cmd);
   install_element (VIEW_NODE, &show_isis_mpls_te_interface_cmd);
-  install_element (ENABLE_NODE, &show_isis_mpls_te_router_cmd);
-  install_element (ENABLE_NODE, &show_isis_mpls_te_interface_cmd);
 
   install_element (ISIS_NODE, &isis_mpls_te_on_cmd);
   install_element (ISIS_NODE, &no_isis_mpls_te_on_cmd);

+ 4 - 6
lib/vty.c

@@ -2668,8 +2668,8 @@ vty_event (enum event event, int sock, struct vty *vty)
     }
 }
 
-DEFUN (config_who,
-       config_who_cmd,
+DEFUN (who,
+       who_cmd,
        "who",
        "Display who is on vty\n")
 {
@@ -3098,11 +3098,10 @@ vty_init (struct thread_master *master_thread)
   /* Install bgp top node. */
   install_node (&vty_node, vty_config_write);
 
-  install_element (RESTRICTED_NODE, &config_who_cmd);
+  install_element (RESTRICTED_NODE, &who_cmd);
   install_element (RESTRICTED_NODE, &show_history_cmd);
-  install_element (VIEW_NODE, &config_who_cmd);
+  install_element (VIEW_NODE, &who_cmd);
   install_element (VIEW_NODE, &show_history_cmd);
-  install_element (ENABLE_NODE, &config_who_cmd);
   install_element (CONFIG_NODE, &line_vty_cmd);
   install_element (CONFIG_NODE, &service_advanced_vty_cmd);
   install_element (CONFIG_NODE, &no_service_advanced_vty_cmd);
@@ -3111,7 +3110,6 @@ vty_init (struct thread_master *master_thread)
   install_element (ENABLE_NODE, &terminal_monitor_cmd);
   install_element (ENABLE_NODE, &terminal_no_monitor_cmd);
   install_element (ENABLE_NODE, &no_terminal_monitor_cmd);
-  install_element (ENABLE_NODE, &show_history_cmd);
 
   install_default (VTY_NODE);
   install_element (VTY_NODE, &exec_timeout_min_cmd);

+ 0 - 37
ospf6d/ospf6d.c

@@ -1840,43 +1840,6 @@ ospf6_init (void)
   INSTALL (VIEW, database_type_self_originated_linkstate_id_cmd);
   INSTALL (VIEW, database_type_self_originated_linkstate_id_detail_cmd);
 
-  INSTALL (ENABLE, database_cmd);
-  INSTALL (ENABLE, database_detail_cmd);
-  INSTALL (ENABLE, database_type_cmd);
-  INSTALL (ENABLE, database_type_detail_cmd);
-  INSTALL (ENABLE, database_id_cmd);
-  INSTALL (ENABLE, database_id_detail_cmd);
-  INSTALL (ENABLE, database_linkstate_id_cmd);
-  INSTALL (ENABLE, database_linkstate_id_detail_cmd);
-  INSTALL (ENABLE, database_router_cmd);
-  INSTALL (ENABLE, database_router_detail_cmd);
-  INSTALL (ENABLE, database_adv_router_cmd);
-  INSTALL (ENABLE, database_adv_router_detail_cmd);
-  INSTALL (ENABLE, database_type_id_cmd);
-  INSTALL (ENABLE, database_type_id_detail_cmd);
-  INSTALL (ENABLE, database_type_linkstate_id_cmd);
-  INSTALL (ENABLE, database_type_linkstate_id_detail_cmd);
-  INSTALL (ENABLE, database_type_router_cmd);
-  INSTALL (ENABLE, database_type_router_detail_cmd);
-  INSTALL (ENABLE, database_type_adv_router_cmd);
-  INSTALL (ENABLE, database_type_adv_router_detail_cmd);
-  INSTALL (ENABLE, database_adv_router_linkstate_id_cmd);
-  INSTALL (ENABLE, database_adv_router_linkstate_id_detail_cmd);
-  INSTALL (ENABLE, database_id_router_cmd);
-  INSTALL (ENABLE, database_id_router_detail_cmd);
-  INSTALL (ENABLE, database_type_id_router_cmd);
-  INSTALL (ENABLE, database_type_id_router_detail_cmd);
-  INSTALL (ENABLE, database_type_adv_router_linkstate_id_cmd);
-  INSTALL (ENABLE, database_type_adv_router_linkstate_id_detail_cmd);
-  INSTALL (ENABLE, database_self_originated_cmd);
-  INSTALL (ENABLE, database_self_originated_detail_cmd);
-  INSTALL (ENABLE, database_type_self_originated_cmd);
-  INSTALL (ENABLE, database_type_self_originated_detail_cmd);
-  INSTALL (ENABLE, database_type_id_self_originated_cmd);
-  INSTALL (ENABLE, database_type_id_self_originated_detail_cmd);
-  INSTALL (ENABLE, database_type_self_originated_linkstate_id_cmd);
-  INSTALL (ENABLE, database_type_self_originated_linkstate_id_detail_cmd);
-
   /* Make ospf protocol socket. */
   ospf6_serv_sock ();
   thread_add_read (master, ospf6_receive, NULL, ospf6_sock);

+ 0 - 2
ospfd/ospf_ri.c

@@ -1621,8 +1621,6 @@ ospf_router_info_register_vty (void)
 {
   install_element (VIEW_NODE, &show_ip_ospf_router_info_cmd);
   install_element (VIEW_NODE, &show_ip_ospf_router_info_pce_cmd);
-  install_element (ENABLE_NODE, &show_ip_ospf_router_info_cmd);
-  install_element (ENABLE_NODE, &show_ip_ospf_router_info_pce_cmd);
 
   install_element (OSPF_NODE, &router_info_area_cmd);
   install_element (OSPF_NODE, &router_info_as_cmd);

+ 0 - 1
zebra/debug.c

@@ -377,7 +377,6 @@ zebra_debug_init (void)
 
   install_element (VIEW_NODE, &show_debugging_zebra_cmd);
 
-  install_element (ENABLE_NODE, &show_debugging_zebra_cmd);
   install_element (ENABLE_NODE, &debug_zebra_events_cmd);
   install_element (ENABLE_NODE, &debug_zebra_nht_cmd);
   install_element (ENABLE_NODE, &debug_zebra_packet_cmd);