summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDonald Sharp <sharpd@cumulusnetworks.com>2016-09-17 07:25:35 -0400
committerDonald Sharp <sharpd@cumulusnetworks.com>2016-09-17 07:25:35 -0400
commit49d41a26c649aa3a098c4316262adcabc7bb840c (patch)
tree98287d4822e0bcc6986e9b9045b75af33bae37de
parent3176e70c104bd26d5fef587f9ed54dd4e9e7cac9 (diff)
isisd, lib, vtysh: Allow extract.pl to fully work
The regular expression for finding DEFUN/ALIAS in extract.pl looks for "DEFUN (" or "ALIAS (" if the *.c file does not have this then it will just silently ignore the cli. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
-rw-r--r--isisd/isis_redist.c100
-rw-r--r--isisd/isis_routemap.c52
-rw-r--r--isisd/isis_vty.c22
-rw-r--r--isisd/isisd.c13
-rw-r--r--lib/thread.c28
-rw-r--r--lib/workqueue.c10
-rwxr-xr-xvtysh/extract.pl.in2
7 files changed, 120 insertions, 107 deletions
diff --git a/isisd/isis_redist.c b/isisd/isis_redist.c
index 690ae4720c..6ad3b7ccd1 100644
--- a/isisd/isis_redist.c
+++ b/isisd/isis_redist.c
@@ -537,20 +537,20 @@ isis_redist_area_finish(struct isis_area *area)
isis_redist_update_zebra_subscriptions(area->isis);
}
-DEFUN(isis_redistribute,
- isis_redistribute_cmd,
- "redistribute (ipv4|ipv6) " QUAGGA_REDIST_STR_ISISD
- " (level-1|level-2) {metric <0-16777215>|route-map WORD}",
- REDIST_STR
- "Redistribute IPv4 routes\n"
- "Redistribute IPv6 routes\n"
- QUAGGA_REDIST_HELP_STR_ISISD
- "Redistribute into level-1\n"
- "Redistribute into level-2\n"
- "Metric for redistributed routes\n"
- "ISIS default metric\n"
- "Route map reference\n"
- "Pointer to route-map entries\n")
+DEFUN (isis_redistribute,
+ isis_redistribute_cmd,
+ "redistribute (ipv4|ipv6) " QUAGGA_REDIST_STR_ISISD
+ " (level-1|level-2) {metric <0-16777215>|route-map WORD}",
+ REDIST_STR
+ "Redistribute IPv4 routes\n"
+ "Redistribute IPv6 routes\n"
+ QUAGGA_REDIST_HELP_STR_ISISD
+ "Redistribute into level-1\n"
+ "Redistribute into level-2\n"
+ "Metric for redistributed routes\n"
+ "ISIS default metric\n"
+ "Route map reference\n"
+ "Pointer to route-map entries\n")
{
struct isis_area *area = vty->index;
int family;
@@ -606,17 +606,17 @@ DEFUN(isis_redistribute,
return 0;
}
-DEFUN(no_isis_redistribute,
- no_isis_redistribute_cmd,
- "no redistribute (ipv4|ipv6) " QUAGGA_REDIST_STR_ISISD
- " (level-1|level-2)",
- NO_STR
- REDIST_STR
- "Redistribute IPv4 routes\n"
- "Redistribute IPv6 routes\n"
- QUAGGA_REDIST_HELP_STR_ISISD
- "Redistribute into level-1\n"
- "Redistribute into level-2\n")
+DEFUN (no_isis_redistribute,
+ no_isis_redistribute_cmd,
+ "no redistribute (ipv4|ipv6) " QUAGGA_REDIST_STR_ISISD
+ " (level-1|level-2)",
+ NO_STR
+ REDIST_STR
+ "Redistribute IPv4 routes\n"
+ "Redistribute IPv6 routes\n"
+ QUAGGA_REDIST_HELP_STR_ISISD
+ "Redistribute into level-1\n"
+ "Redistribute into level-2\n")
{
struct isis_area *area = vty->index;
int type;
@@ -650,21 +650,21 @@ DEFUN(no_isis_redistribute,
return 0;
}
-DEFUN(isis_default_originate,
- isis_default_originate_cmd,
- "default-information originate (ipv4|ipv6) (level-1|level-2) "
- "{always|metric <0-16777215>|route-map WORD}",
- "Control distribution of default information\n"
- "Distribute a default route\n"
- "Distribute default route for IPv4\n"
- "Distribute default route for IPv6\n"
- "Distribute default route into level-1\n"
- "Distribute default route into level-2\n"
- "Always advertise default route\n"
- "Metric for default route\n"
- "ISIS default metric\n"
- "Route map reference\n"
- "Pointer to route-map entries\n")
+DEFUN (isis_default_originate,
+ isis_default_originate_cmd,
+ "default-information originate (ipv4|ipv6) (level-1|level-2) "
+ "{always|metric <0-16777215>|route-map WORD}",
+ "Control distribution of default information\n"
+ "Distribute a default route\n"
+ "Distribute default route for IPv4\n"
+ "Distribute default route for IPv6\n"
+ "Distribute default route into level-1\n"
+ "Distribute default route into level-2\n"
+ "Always advertise default route\n"
+ "Metric for default route\n"
+ "ISIS default metric\n"
+ "Route map reference\n"
+ "Pointer to route-map entries\n")
{
struct isis_area *area = vty->index;
int family;
@@ -722,16 +722,16 @@ DEFUN(isis_default_originate,
return 0;
}
-DEFUN(no_isis_default_originate,
- no_isis_default_originate_cmd,
- "no default-information originate (ipv4|ipv6) (level-1|level-2)",
- NO_STR
- "Control distribution of default information\n"
- "Distribute a default route\n"
- "Distribute default route for IPv4\n"
- "Distribute default route for IPv6\n"
- "Distribute default route into level-1\n"
- "Distribute default route into level-2\n")
+DEFUN (no_isis_default_originate,
+ no_isis_default_originate_cmd,
+ "no default-information originate (ipv4|ipv6) (level-1|level-2)",
+ NO_STR
+ "Control distribution of default information\n"
+ "Distribute a default route\n"
+ "Distribute default route for IPv4\n"
+ "Distribute default route for IPv6\n"
+ "Distribute default route into level-1\n"
+ "Distribute default route into level-2\n")
{
struct isis_area *area = vty->index;
diff --git a/isisd/isis_routemap.c b/isisd/isis_routemap.c
index 6ae12d3d10..fdc0100e77 100644
--- a/isisd/isis_routemap.c
+++ b/isisd/isis_routemap.c
@@ -344,29 +344,29 @@ isis_route_set_delete (struct vty *vty, struct route_map_index *index,
/* ------------------------------------------------------------*/
-DEFUN(match_ip_address,
- match_ip_address_cmd,
- "match ip address (<1-199>|<1300-2699>|WORD)",
- MATCH_STR
- IP_STR
- "Match address of route\n"
- "IP access-list number\n"
- "IP access-list number (expanded range)\n"
- "IP Access-list name\n")
+DEFUN (match_ip_address,
+ match_ip_address_cmd,
+ "match ip address (<1-199>|<1300-2699>|WORD)",
+ MATCH_STR
+ IP_STR
+ "Match address of route\n"
+ "IP access-list number\n"
+ "IP access-list number (expanded range)\n"
+ "IP Access-list name\n")
{
return isis_route_match_add(vty, vty->index, "ip address", argv[0]);
}
-DEFUN(no_match_ip_address,
- no_match_ip_address_val_cmd,
- "no match ip address (<1-199>|<1300-2699>|WORD)",
- NO_STR
- MATCH_STR
- IP_STR
- "Match address of route\n"
- "IP access-list number\n"
- "IP access-list number (expanded range)\n"
- "IP Access-list name\n")
+DEFUN (no_match_ip_address,
+ no_match_ip_address_val_cmd,
+ "no match ip address (<1-199>|<1300-2699>|WORD)",
+ NO_STR
+ MATCH_STR
+ IP_STR
+ "Match address of route\n"
+ "IP access-list number\n"
+ "IP access-list number (expanded range)\n"
+ "IP Access-list name\n")
{
if (argc == 0)
return isis_route_match_delete(vty, vty->index, "ip address", NULL);
@@ -446,13 +446,13 @@ DEFUN (no_match_ipv6_address,
return isis_route_match_delete(vty, vty->index, "ipv6 address", argv[0]);
}
-ALIAS(no_match_ipv6_address,
- no_match_ipv6_address_cmd,
- "no match ipv6 address",
- NO_STR
- MATCH_STR
- IPV6_STR
- "Match IPv6 address of route\n")
+ALIAS (no_match_ipv6_address,
+ no_match_ipv6_address_cmd,
+ "no match ipv6 address",
+ NO_STR
+ MATCH_STR
+ IPV6_STR
+ "Match IPv6 address of route\n")
/* ------------------------------------------------------------*/
diff --git a/isisd/isis_vty.c b/isisd/isis_vty.c
index 4148eb55b9..53c635ea61 100644
--- a/isisd/isis_vty.c
+++ b/isisd/isis_vty.c
@@ -1566,21 +1566,21 @@ DEFUN (area_lsp_mtu,
return area_lsp_mtu_set(vty, lsp_mtu);
}
-DEFUN(no_area_lsp_mtu,
- no_area_lsp_mtu_cmd,
- "no lsp-mtu",
- NO_STR
- "Configure the maximum size of generated LSPs\n")
+DEFUN (no_area_lsp_mtu,
+ no_area_lsp_mtu_cmd,
+ "no lsp-mtu",
+ NO_STR
+ "Configure the maximum size of generated LSPs\n")
{
return area_lsp_mtu_set(vty, DEFAULT_LSP_MTU);
}
-ALIAS(no_area_lsp_mtu,
- no_area_lsp_mtu_arg_cmd,
- "no lsp-mtu <128-4352>",
- NO_STR
- "Configure the maximum size of generated LSPs\n"
- "Maximum size of generated LSPs\n");
+ALIAS (no_area_lsp_mtu,
+ no_area_lsp_mtu_arg_cmd,
+ "no lsp-mtu <128-4352>",
+ NO_STR
+ "Configure the maximum size of generated LSPs\n"
+ "Maximum size of generated LSPs\n");
DEFUN (is_type,
is_type_cmd,
diff --git a/isisd/isisd.c b/isisd/isisd.c
index 87d45aba37..4d7f475616 100644
--- a/isisd/isisd.c
+++ b/isisd/isisd.c
@@ -1234,6 +1234,19 @@ DEFUN (debug_isis_lsp_sched,
return CMD_SUCCESS;
}
+DEFUN (no_debug_isis_lsp_sched,
+ no_debug_isis_lsp_sched_cmd,
+ "no debug isis lsp-sched",
+ UNDEBUG_STR
+ "IS-IS information\n"
+ "IS-IS scheduling of LSP generation\n")
+{
+ isis->debugs &= ~DEBUG_LSP_SCHED;
+ print_debug (vty, DEBUG_LSP_SCHED, 0);
+
+ return CMD_SUCCESS;
+}
+
DEFUN (show_hostname,
show_hostname_cmd,
"show isis hostname",
diff --git a/lib/thread.c b/lib/thread.c
index a128786c3d..573e9f725d 100644
--- a/lib/thread.c
+++ b/lib/thread.c
@@ -287,13 +287,13 @@ cpu_record_print(struct vty *vty, thread_type filter)
vty_out_cpu_thread_history(vty, &tmp);
}
-DEFUN(show_thread_cpu,
- show_thread_cpu_cmd,
- "show thread cpu [FILTER]",
- SHOW_STR
- "Thread information\n"
- "Thread CPU usage\n"
- "Display filter (rwtexb)\n")
+DEFUN (show_thread_cpu,
+ show_thread_cpu_cmd,
+ "show thread cpu [FILTER]",
+ SHOW_STR
+ "Thread information\n"
+ "Thread CPU usage\n"
+ "Display filter (rwtexb)\n")
{
int i = 0;
thread_type filter = (thread_type) -1U;
@@ -369,13 +369,13 @@ cpu_record_clear (thread_type filter)
tmp);
}
-DEFUN(clear_thread_cpu,
- clear_thread_cpu_cmd,
- "clear thread cpu [FILTER]",
- "Clear stored data\n"
- "Thread information\n"
- "Thread CPU usage\n"
- "Display filter (rwtexb)\n")
+DEFUN (clear_thread_cpu,
+ clear_thread_cpu_cmd,
+ "clear thread cpu [FILTER]",
+ "Clear stored data\n"
+ "Thread information\n"
+ "Thread CPU usage\n"
+ "Display filter (rwtexb)\n")
{
int i = 0;
thread_type filter = (thread_type) -1U;
diff --git a/lib/workqueue.c b/lib/workqueue.c
index d351beb124..772749403c 100644
--- a/lib/workqueue.c
+++ b/lib/workqueue.c
@@ -178,11 +178,11 @@ work_queue_item_requeue (struct work_queue *wq, struct listnode *ln)
LISTNODE_ATTACH (wq->items, ln); /* attach to end of list */
}
-DEFUN(show_work_queues,
- show_work_queues_cmd,
- "show work-queues",
- SHOW_STR
- "Work Queue information\n")
+DEFUN (show_work_queues,
+ show_work_queues_cmd,
+ "show work-queues",
+ SHOW_STR
+ "Work Queue information\n")
{
struct listnode *node;
struct work_queue *wq;
diff --git a/vtysh/extract.pl.in b/vtysh/extract.pl.in
index 293a8a2fe4..b7533881a3 100755
--- a/vtysh/extract.pl.in
+++ b/vtysh/extract.pl.in
@@ -212,7 +212,7 @@ foreach (@ARGV) {
}
}
-my $bad_cli_stomps = 107;
+my $bad_cli_stomps = 108;
# Currently we have $bad_cli_stomps. This was determined by
# running this script and counting up the collisions from what
# was returned.