summaryrefslogtreecommitdiffstats
path: root/isisd/isis_bfd.c
diff options
context:
space:
mode:
authorPhilippe Guibert <philippe.guibert@6wind.com>2019-04-15 17:20:25 +0200
committerPhilippe Guibert <philippe.guibert@6wind.com>2019-05-14 16:49:49 +0200
commit9beff0bda93a1ab398647cfda6e5efc06222a46c (patch)
treee536633959fe4d7e5d903aa74fab0ae290e8c97d /isisd/isis_bfd.c
parentMerge pull request #4312 from lkrishnamoor/json_cli_bug_fix (diff)
downloadfrr-9beff0bda93a1ab398647cfda6e5efc06222a46c.tar.xz
frr-9beff0bda93a1ab398647cfda6e5efc06222a46c.zip
bfdd, lib, bgpd: add bfd cbit usage
bfd cbit is a value carried out in bfd messages, that permit to keep or not, the independence between control plane and dataplane. In other words, while most of the cases plan to flush entries, when bfd goes down, there are some cases where that bfd event should be ignored. this is the case with non stop forwarding mechanisms where entries may be kept. this is the case for BGP, when graceful restart capability is used. If BFD event down happens, and bgp is in graceful restart mode, it is wished to ignore the BFD event while waiting for the remote router to restart. The changes take into account the following: - add a config flag across zebra layer so that daemon can set or not the cbit capability. - ability for daemons to read the remote bfd capability associated to a bfd notification. - in bfdd, according to the value, the cbit value is set - in bfdd, the received value is retrived and stored in the bfd session context. - by default, the local cbit announced to remote is set to 1 while preservation of the local path is not set. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Diffstat (limited to 'isisd/isis_bfd.c')
-rw-r--r--isisd/isis_bfd.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/isisd/isis_bfd.c b/isisd/isis_bfd.c
index fccef0169..fa89c8004 100644
--- a/isisd/isis_bfd.c
+++ b/isisd/isis_bfd.c
@@ -98,7 +98,8 @@ static int isis_bfd_interface_dest_update(ZAPI_CALLBACK_ARGS)
struct prefix dst_ip;
int status;
- ifp = bfd_get_peer_info(zclient->ibuf, &dst_ip, NULL, &status, vrf_id);
+ ifp = bfd_get_peer_info(zclient->ibuf, &dst_ip, NULL, &status,
+ NULL, vrf_id);
if (!ifp || dst_ip.family != AF_INET)
return 0;
@@ -217,6 +218,7 @@ static void bfd_handle_adj_down(struct isis_adjacency *adj)
adj->circuit->interface->name,
0, /* ttl */
0, /* multihop */
+ 1, /* control plane independent bit is on */
ZEBRA_BFD_DEST_DEREGISTER,
0, /* set_flag */
VRF_DEFAULT);
@@ -258,6 +260,7 @@ static void bfd_handle_adj_up(struct isis_adjacency *adj, int command)
circuit->interface->name,
0, /* ttl */
0, /* multihop */
+ 1, /* control plane independent bit is on */
command,
0, /* set flag */
VRF_DEFAULT);