aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/mpls/mpls_input.c
diff options
context:
space:
mode:
authorNeale Ranns <neale@graphiant.com>2022-08-09 01:24:41 +0000
committerBeno�t Ganne <bganne@cisco.com>2022-08-11 06:55:11 +0000
commit41a85c0a263302d8a9e9cf758d6b259aaf957c49 (patch)
treefdab6107bf6f70c73e889b86c78d15c8026aeb52 /src/vnet/mpls/mpls_input.c
parente22a7041626cf1ebee7534d84068d48e8671a6ab (diff)
mpls: Use the .api for the definition of error/info counters
Type: improvement Signed-off-by: Neale Ranns <neale@graphiant.com> Change-Id: I9d25f5459ab70d9cf8556e44cfddfd7029e5b540
Diffstat (limited to 'src/vnet/mpls/mpls_input.c')
-rw-r--r--src/vnet/mpls/mpls_input.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/vnet/mpls/mpls_input.c b/src/vnet/mpls/mpls_input.c
index 37fa1aead12..c18cbda6315 100644
--- a/src/vnet/mpls/mpls_input.c
+++ b/src/vnet/mpls/mpls_input.c
@@ -19,6 +19,7 @@
#include <vnet/pg/pg.h>
#include <vnet/mpls/mpls.h>
#include <vnet/feature/feature.h>
+#include <vnet/mpls/mpls.api_enum.h>
typedef struct {
u32 next_index;
@@ -236,12 +237,6 @@ VLIB_NODE_FN (mpls_input_node) (vlib_main_t * vm,
return mpls_input_inline (vm, node, from_frame);
}
-static char * mpls_error_strings[] = {
-#define mpls_error(n,s) s,
-#include "error.def"
-#undef mpls_error
-};
-
VLIB_REGISTER_NODE (mpls_input_node) = {
.name = "mpls-input",
/* Takes a vector of packets. */
@@ -250,7 +245,7 @@ VLIB_REGISTER_NODE (mpls_input_node) = {
.runtime_data_bytes = sizeof(mpls_input_runtime_t),
.n_errors = MPLS_N_ERROR,
- .error_strings = mpls_error_strings,
+ .error_counters = mpls_error_counters,
.n_next_nodes = MPLS_INPUT_N_NEXT,
.next_nodes = {