summaryrefslogtreecommitdiff
path: root/proto/ospf/neighbor.c
diff options
context:
space:
mode:
authorOndrej Zajicek (work) <santiago@crfreenet.org>2019-07-17 16:20:35 +0200
committerOndrej Zajicek (work) <santiago@crfreenet.org>2019-07-17 16:20:35 +0200
commitcf7ff99513728e4e405508e5ccd7522289d4ec82 (patch)
tree628cf52de928cb52340b82c1e19ae1d2d2d21ba8 /proto/ospf/neighbor.c
parent2eaf65ec607b68748744fa8e0d596cf1f3ba117a (diff)
BFD: Support for VRFs
Allow multiple BFD instances in separate VRFs, dispatch BFD requests according to VRFs. Thanks to Alexander Zubkov for notice and patches.
Diffstat (limited to 'proto/ospf/neighbor.c')
-rw-r--r--proto/ospf/neighbor.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/proto/ospf/neighbor.c b/proto/ospf/neighbor.c
index 50ef6a49..112625c8 100644
--- a/proto/ospf/neighbor.c
+++ b/proto/ospf/neighbor.c
@@ -771,8 +771,11 @@ ospf_neigh_bfd_hook(struct bfd_request *req)
void
ospf_neigh_update_bfd(struct ospf_neighbor *n, int use_bfd)
{
+ struct ospf_proto *p = n->ifa->oa->po;
+
if (use_bfd && !n->bfd_req)
- n->bfd_req = bfd_request_session(n->pool, n->ip, n->ifa->addr->ip, n->ifa->iface,
+ n->bfd_req = bfd_request_session(n->pool, n->ip, n->ifa->addr->ip,
+ n->ifa->iface, p->p.vrf,
ospf_neigh_bfd_hook, n);
if (!use_bfd && n->bfd_req)