[ovs-dev] [PATCH] OFPROTO: Integration of BFD Interface Status into FastFailover Group Table

Niels van Adrichem N.L.M.vanAdrichem at tudelft.nl
Wed Oct 15 13:54:52 UTC 2014


Integration of each interface' status as confirmed by BFD into the
FastFailover Group table. When BFD is configured and function
bfd_forwarding() reports false, odp_port_is_alive also reports false in
order to have a watched interface report false and omit to another
backup.

Test-suite has been succesfully run, as well as testing with ICMP echo
requests and replies that traffic was succesfully rerouted over the
backup path. More extensive load-consumption tests with a function that
only checked whether (bfd->state == STATE_UP) have been succesfully
performed, but was later changed to use the larger function
bfd_forwarding() as it captures all possible exceptions and is properly
mutually excluded.

Signed-off-by: Niels van Adrichem <n.l.m.vanadrichem at tudelft.nl>
---
 ofproto/ofproto-dpif-xlate.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/ofproto/ofproto-dpif-xlate.c b/ofproto/ofproto-dpif-xlate.c
index 07a1f29..7b8bbb3 100644
--- a/ofproto/ofproto-dpif-xlate.c
+++ b/ofproto/ofproto-dpif-xlate.c
@@ -1247,6 +1247,7 @@ static bool
 odp_port_is_alive(const struct xlate_ctx *ctx, ofp_port_t ofp_port)
 {
     struct xport *xport;
+    struct bfd *bfd;
 
     xport = get_ofp_port(ctx->xbridge, ofp_port);
     if (!xport || xport->config & OFPUTIL_PC_PORT_DOWN ||
@@ -1254,6 +1255,11 @@ odp_port_is_alive(const struct xlate_ctx *ctx, ofp_port_t ofp_port)
         return false;
     }
 
+    bfd = xport->bfd;
+    if(bfd && !bfd_forwarding(bfd)) {
+        return false;
+    }
+
     return true;
 }



More information about the dev mailing list