]> git.puffer.fish Git - matthieu/frr.git/commitdiff
zebra,fpm: fix force disable next hop groups
authorRafael Zalamena <rzalamena@opensourcerouting.org>
Fri, 12 Jun 2020 15:21:28 +0000 (12:21 -0300)
committerRafael Zalamena <rzalamena@opensourcerouting.org>
Fri, 10 Jul 2020 16:13:55 +0000 (13:13 -0300)
`force_nhg` is only settable when calling from `fpm`, so if the kernel
was using next hop groups it would override our knob.

Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
zebra/rt_netlink.c

index 9883e73876dcb82fc09ffd00b320c7bfe30925e4..40a7eeba8e616a6e823a22c670da672a4e5ebf8b 100644 (file)
@@ -1713,7 +1713,7 @@ ssize_t netlink_route_multipath_msg_encode(int cmd,
                nl_attr_nest_end(&req->n, nest);
        }
 
-       if (kernel_nexthops_supported() || force_nhg) {
+       if ((!fpm && kernel_nexthops_supported()) || (fpm && force_nhg)) {
                /* Kernel supports nexthop objects */
                if (IS_ZEBRA_DEBUG_KERNEL)
                        zlog_debug("%s: %pFX nhg_id is %u", __func__, p,