summaryrefslogtreecommitdiff
path: root/zebra/zebra_dplane.c
diff options
context:
space:
mode:
Diffstat (limited to 'zebra/zebra_dplane.c')
-rw-r--r--zebra/zebra_dplane.c16
1 files changed, 10 insertions, 6 deletions
diff --git a/zebra/zebra_dplane.c b/zebra/zebra_dplane.c
index 7f993442a6..ca72ea5227 100644
--- a/zebra/zebra_dplane.c
+++ b/zebra/zebra_dplane.c
@@ -1161,7 +1161,8 @@ zebra_nhlfe_t *dplane_ctx_add_nhlfe(struct zebra_dplane_ctx *ctx,
enum nexthop_types_t nh_type,
union g_addr *gate,
ifindex_t ifindex,
- mpls_label_t out_label)
+ uint8_t num_labels,
+ mpls_label_t out_labels[])
{
zebra_nhlfe_t *nhlfe;
@@ -1169,7 +1170,7 @@ zebra_nhlfe_t *dplane_ctx_add_nhlfe(struct zebra_dplane_ctx *ctx,
nhlfe = zebra_mpls_lsp_add_nhlfe(&(ctx->u.lsp),
lsp_type, nh_type, gate,
- ifindex, out_label);
+ ifindex, num_labels, out_labels);
return nhlfe;
}
@@ -1507,7 +1508,8 @@ static int dplane_ctx_route_init(struct zebra_dplane_ctx *ctx,
ctx->u.rinfo.zd_safi = info->safi;
/* Copy nexthops; recursive info is included too */
- copy_nexthops(&(ctx->u.rinfo.zd_ng.nexthop), re->ng->nexthop, NULL);
+ copy_nexthops(&(ctx->u.rinfo.zd_ng.nexthop),
+ re->nhe->nhg->nexthop, NULL);
/* Ensure that the dplane's nexthops flags are clear. */
for (ALL_NEXTHOPS(ctx->u.rinfo.zd_ng, nexthop))
@@ -1660,7 +1662,8 @@ static int dplane_ctx_lsp_init(struct zebra_dplane_ctx *ctx,
nhlfe->nexthop->type,
&(nhlfe->nexthop->gate),
nhlfe->nexthop->ifindex,
- nhlfe->nexthop->nh_label->label[0]);
+ nhlfe->nexthop->nh_label->num_labels,
+ nhlfe->nexthop->nh_label->label);
if (new_nhlfe == NULL || new_nhlfe->nexthop == NULL) {
ret = ENOMEM;
@@ -1746,7 +1749,7 @@ static int dplane_ctx_pw_init(struct zebra_dplane_ctx *ctx,
if (re)
copy_nexthops(&(ctx->u.pw.nhg.nexthop),
- re->ng->nexthop, NULL);
+ re->nhe->nhg->nexthop, NULL);
route_unlock_node(rn);
}
@@ -1842,7 +1845,7 @@ dplane_route_update_internal(struct route_node *rn,
* We'll need these to do per-nexthop deletes.
*/
copy_nexthops(&(ctx->u.rinfo.zd_old_ng.nexthop),
- old_re->ng->nexthop, NULL);
+ old_re->nhe->nhg->nexthop, NULL);
#endif /* !HAVE_NETLINK */
}
@@ -2811,6 +2814,7 @@ int dplane_provider_register(const char *name,
TAILQ_INIT(&(p->dp_ctx_in_q));
TAILQ_INIT(&(p->dp_ctx_out_q));
+ p->dp_flags = flags;
p->dp_priority = prio;
p->dp_fp = fp;
p->dp_start = start_fp;