From 976b259be2ce9725f1d6756c14ff81069634a396 Mon Sep 17 00:00:00 2001 From: Neale Ranns Date: Wed, 4 Dec 2019 06:11:00 +0000 Subject: 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 Signed-off-by: Alexander Chernavin Change-Id: I5158b4fa1ebe87381ff8707bb173217f56ea274a --- src/vnet/mpls/mpls_api.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'src/vnet/mpls') diff --git a/src/vnet/mpls/mpls_api.c b/src/vnet/mpls/mpls_api.c index 25bd353c62b..97928a744d8 100644 --- a/src/vnet/mpls/mpls_api.c +++ b/src/vnet/mpls/mpls_api.c @@ -192,13 +192,11 @@ mpls_route_add_del_t_handler (vnet_main_t * vnm, goto out; } - rv = fib_api_route_add_del (mp->mr_is_add, - mp->mr_is_multipath, - fib_index, - &pfx, - (mp->mr_route.mr_is_multicast ? - FIB_ENTRY_FLAG_MULTICAST : - FIB_ENTRY_FLAG_NONE), rpaths); + rv = fib_api_route_add_del ( + mp->mr_is_add, mp->mr_is_multipath, fib_index, &pfx, FIB_SOURCE_API, + (mp->mr_route.mr_is_multicast ? FIB_ENTRY_FLAG_MULTICAST : + FIB_ENTRY_FLAG_NONE), + rpaths); if (mp->mr_is_add && 0 == rv) *stats_index = fib_table_entry_get_stats_index (fib_index, &pfx); -- cgit 1.2.3-korg