summaryrefslogtreecommitdiffstats
path: root/src/vnet/fib/fib_table.h
diff options
context:
space:
mode:
authorNeale Ranns <nranns@cisco.com>2019-12-04 06:11:00 +0000
committerNeale Ranns <neale@graphiant.com>2021-03-16 12:12:23 +0000
commit976b259be2ce9725f1d6756c14ff81069634a396 (patch)
treef4117b32e9230e5c313474a158dbfa847943b99d /src/vnet/fib/fib_table.h
parent400ce717ac043ceec404103dbaa87dd17d92feb7 (diff)
fib: Allow the creation of new source on the API
Type: feature an client can dump the existing sources, examine their priorities, then define thier own source. Usefull if a client wants to distingusih between say, static, ospf, bgp, etc routes it has added over the API. Signed-off-by: Neale Ranns <nranns@cisco.com> Signed-off-by: Alexander Chernavin <achernavin@netgate.com> Change-Id: I5158b4fa1ebe87381ff8707bb173217f56ea274a
Diffstat (limited to 'src/vnet/fib/fib_table.h')
-rw-r--r--src/vnet/fib/fib_table.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/vnet/fib/fib_table.h b/src/vnet/fib/fib_table.h
index 201170707a8..11137e173cf 100644
--- a/src/vnet/fib/fib_table.h
+++ b/src/vnet/fib/fib_table.h
@@ -941,6 +941,17 @@ extern void fib_table_walk(u32 fib_index,
void *ctx);
/**
+ * @brief Walk all entries in a FIB table
+ * N.B: This is NOT safe to deletes. If you need to delete walk the whole
+ * table and store elements in a vector, then delete the elements
+ */
+extern void fib_table_walk_w_src(u32 fib_index,
+ fib_protocol_t proto,
+ fib_source_t src,
+ fib_table_walk_fn_t fn,
+ void *ctx);
+
+/**
* @brief Walk all entries in a sub-tree FIB table. The 'root' paraneter
* is the prefix at the root of the sub-tree.
* N.B: This is NOT safe to deletes. If you need to delete walk the whole