diff options
author | Mobashshera Rasool <mrasool@vmware.com> | 2021-01-28 09:50:39 +0100 |
---|---|---|
committer | Mobashshera Rasool <mrasool@vmware.com> | 2021-02-01 10:05:52 +0100 |
commit | 1958143e302c7d4f791404dc9d15a9c017a71b22 (patch) | |
tree | 92e7cdd310085e21ce6436243dc61775835b3749 /ospf6d/ospf6_zebra.c | |
parent | Merge pull request #7960 from kishorekunal01/bgp_fix_allowas_in (diff) | |
download | frr-1958143e302c7d4f791404dc9d15a9c017a71b22.tar.xz frr-1958143e302c7d4f791404dc9d15a9c017a71b22.zip |
ospf6d: add CLI to control maximum paths for routes.
CLI added:
maximum-paths (1-64)
Issue: #7961
Signed-off-by: Mobashshera Rasool <mrasool@vmware.com>
Diffstat (limited to 'ospf6d/ospf6_zebra.c')
-rw-r--r-- | ospf6d/ospf6_zebra.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/ospf6d/ospf6_zebra.c b/ospf6d/ospf6_zebra.c index 7a8027a37..2b7072d34 100644 --- a/ospf6d/ospf6_zebra.c +++ b/ospf6d/ospf6_zebra.c @@ -343,7 +343,14 @@ static void ospf6_zebra_route_update(int type, struct ospf6_route *request, api.safi = SAFI_UNICAST; api.prefix = *dest; SET_FLAG(api.message, ZAPI_MESSAGE_NEXTHOP); - api.nexthop_num = MIN(nhcount, MULTIPATH_NUM); + + if (nhcount > ospf6->max_multipath) { + if (IS_OSPF6_DEBUG_ZEBRA(SEND)) + zlog_debug( + " Nexthop count is greater than configured maximum-path, hence ignore the extra nexthops"); + } + api.nexthop_num = MIN(nhcount, ospf6->max_multipath); + ospf6_route_zebra_copy_nexthops(request, api.nexthops, api.nexthop_num, api.vrf_id); SET_FLAG(api.message, ZAPI_MESSAGE_METRIC); |