summaryrefslogtreecommitdiffstats
path: root/zebra/zebra_rib.c
diff options
context:
space:
mode:
authorDonald Sharp <sharpd@nvidia.com>2024-06-17 16:42:41 +0200
committerDonald Sharp <sharpd@nvidia.com>2024-09-05 21:52:05 +0200
commit98b11de9f60c16e61a581b03a97294563eb9f673 (patch)
tree3cc640f574e163519b8c7a603931a6c74f2f13ea /zebra/zebra_rib.c
parentzebra: Limit queue depth in dplane_fpm_nl (diff)
downloadfrr-98b11de9f60c16e61a581b03a97294563eb9f673.tar.xz
frr-98b11de9f60c16e61a581b03a97294563eb9f673.zip
zebra: Modify show `zebra dplane providers` to give more data
The show zebra dplane provider command was ommitting the input and output queues to the dplane itself. It would be nice to have this insight as well. New output: r1# show zebra dplane providers dataplane Incoming Queue from Zebra: 100 Zebra dataplane providers: Kernel (1): in: 6, q: 0, q_max: 3, out: 6, q: 14, q_max: 3 dplane_fpm_nl (2): in: 6, q: 10, q_max: 3, out: 6, q: 0, q_max: 3 dataplane Outgoing Queue to Zebra: 43 r1# Signed-off-by: Donald Sharp <sharpd@nvidia.com>
Diffstat (limited to 'zebra/zebra_rib.c')
-rw-r--r--zebra/zebra_rib.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/zebra/zebra_rib.c b/zebra/zebra_rib.c
index d53b27a38..075cc2ffb 100644
--- a/zebra/zebra_rib.c
+++ b/zebra/zebra_rib.c
@@ -5108,6 +5108,17 @@ static int rib_dplane_results(struct dplane_ctx_list_head *ctxlist)
return 0;
}
+uint32_t zebra_rib_dplane_results_count(void)
+{
+ uint32_t count;
+
+ frr_with_mutex (&dplane_mutex) {
+ count = dplane_ctx_queue_count(&rib_dplane_q);
+ }
+
+ return count;
+}
+
/*
* Ensure there are no empty slots in the route_info array.
* Every route type in zebra should be present there.