MPLS Unifom mode
- support both pipe and uniform modes for all MPLS LSP
- all API programming for output-labels requires that the mode (and associated data) is specificed
- API changes in MPLS, BIER and IP are involved
- new DPO [sub] types for MPLS labels to handle the two modes.
Change-Id: I87b76401e996f10dfbdbe4552ff6b19af958783c
Signed-off-by: Neale Ranns <nranns@cisco.com>
diff --git a/src/vnet/fib/fib_entry_src.c b/src/vnet/fib/fib_entry_src.c
index 6dc0c73..ec8c739 100644
--- a/src/vnet/fib/fib_entry_src.c
+++ b/src/vnet/fib/fib_entry_src.c
@@ -212,6 +212,7 @@
fib_entry_src_valid_out_label (mpls_label_t label)
{
return ((MPLS_LABEL_IS_REAL(label) ||
+ MPLS_LABEL_POP == label ||
MPLS_IETF_IPV4_EXPLICIT_NULL_LABEL == label ||
MPLS_IETF_IPV6_EXPLICIT_NULL_LABEL == label ||
MPLS_IETF_IMPLICIT_NULL_LABEL == label));
@@ -330,6 +331,7 @@
&nh->path_dpo);
fib_path_stack_mpls_disp(path_index,
fib_prefix_get_payload_proto(&ctx->fib_entry->fe_prefix),
+ FIB_MPLS_LSP_MODE_PIPE,
&nh->path_dpo);
break;
@@ -391,7 +393,7 @@
switch (path_ext->fpe_type)
{
case FIB_PATH_EXT_MPLS:
- if (fib_entry_src_valid_out_label(path_ext->fpe_label_stack[0]))
+ if (fib_entry_src_valid_out_label(path_ext->fpe_label_stack[0].fml_value))
{
/*
* found a matching extension. stack it to obtain the forwarding