diff options
| author | Mark Stapp <mjs@voltanet.io> | 2020-08-27 07:58:37 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-08-27 07:58:37 -0400 |
| commit | da2f67007844948e5d0d2ecdf24ae7124468e47a (patch) | |
| tree | b316cf7b413ee0e2720fe2e02f95b2839cf722a1 | |
| parent | 4a097aaf88f2d6f351634f82923a88c934e2ff61 (diff) | |
| parent | b96f64f76f990c6eda5ce1ccbe87c2ee585b85df (diff) | |
Merge pull request #7008 from donaldsharp/zebra_lies
Zebra lies
| -rw-r--r-- | zebra/zebra_dplane.c | 16 | ||||
| -rw-r--r-- | zebra/zebra_rib.c | 4 |
2 files changed, 9 insertions, 11 deletions
diff --git a/zebra/zebra_dplane.c b/zebra/zebra_dplane.c index 6e8d35aa77..9771235717 100644 --- a/zebra/zebra_dplane.c +++ b/zebra/zebra_dplane.c @@ -1911,10 +1911,11 @@ int dplane_ctx_route_init(struct zebra_dplane_ctx *ctx, enum dplane_op_e op, * If its a delete we only use the prefix anyway, so this only * matters for INSTALL/UPDATE. */ - if (((op == DPLANE_OP_ROUTE_INSTALL) - || (op == DPLANE_OP_ROUTE_UPDATE)) - && !CHECK_FLAG(nhe->flags, NEXTHOP_GROUP_INSTALLED) - && !CHECK_FLAG(nhe->flags, NEXTHOP_GROUP_QUEUED)) { + if (zebra_nhg_kernel_nexthops_enabled() + && (((op == DPLANE_OP_ROUTE_INSTALL) + || (op == DPLANE_OP_ROUTE_UPDATE)) + && !CHECK_FLAG(nhe->flags, NEXTHOP_GROUP_INSTALLED) + && !CHECK_FLAG(nhe->flags, NEXTHOP_GROUP_QUEUED))) { ret = ENOENT; goto done; } @@ -2352,11 +2353,8 @@ dplane_route_update_internal(struct route_node *rn, if (ret == AOK) result = ZEBRA_DPLANE_REQUEST_QUEUED; else { - if (ret == ENOENT) - result = ZEBRA_DPLANE_REQUEST_SUCCESS; - else - atomic_fetch_add_explicit(&zdplane_info.dg_route_errors, - 1, memory_order_relaxed); + atomic_fetch_add_explicit(&zdplane_info.dg_route_errors, 1, + memory_order_relaxed); if (ctx) dplane_ctx_free(&ctx); } diff --git a/zebra/zebra_rib.c b/zebra/zebra_rib.c index 8852ee9467..5fcb513e3c 100644 --- a/zebra/zebra_rib.c +++ b/zebra/zebra_rib.c @@ -499,8 +499,8 @@ void rib_install_kernel(struct route_node *rn, struct route_entry *re, srcdest_rnode2str(rn, str, sizeof(str)); flog_err(EC_ZEBRA_DP_INSTALL_FAIL, - "%u:%s: Failed to enqueue dataplane install", - re->vrf_id, str); + "%u:%u:%s: Failed to enqueue dataplane install", + re->vrf_id, re->table, str); break; } case ZEBRA_DPLANE_REQUEST_SUCCESS: |
