aboutsummaryrefslogtreecommitdiffstats
path: root/hicn-plugin/src/route.c
diff options
context:
space:
mode:
authorMauro Sardara <msardara@cisco.com>2022-12-12 16:19:35 +0000
committerMauro Sardara <msardara@cisco.com>2023-01-10 16:09:24 +0000
commit55d06ad1cd4f64fc7382bcaf14dc57c1f16db8fe (patch)
treecb2c361050e90a27d32ffcbc93e27b57c45ae583 /hicn-plugin/src/route.c
parenta5f7941f49160021506ecae0da090f0b204b75ea (diff)
feat: upgrade to VPP 22.10v22.10-rc0
Change-Id: I556bd8c44f0ff7a631a0df34b498ffd7952fcf4a Signed-off-by: Mauro Sardara <msardara@cisco.com>
Diffstat (limited to 'hicn-plugin/src/route.c')
-rw-r--r--hicn-plugin/src/route.c17
1 files changed, 8 insertions, 9 deletions
diff --git a/hicn-plugin/src/route.c b/hicn-plugin/src/route.c
index 0c96e1412..a2e72b9c1 100644
--- a/hicn-plugin/src/route.c
+++ b/hicn-plugin/src/route.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2021 Cisco and/or its affiliates.
+ * Copyright (c) 2021-2023 Cisco and/or its affiliates.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
@@ -273,7 +273,7 @@ sync_hicn_fib_entry (hicn_dpo_ctx_t *fib_entry, hicn_face_id_t **pvec_faces)
fib_entry->proto);
ADD_FACE (nh);
HICN_DEBUG ("Added new HICN face: %d because of route prefix %U",
- face_id, format_ip_prefix, &_fib_entry->fe_prefix);
+ face_id, format_fib_prefix, &_fib_entry->fe_prefix);
}
else if (dpo->dpoi_type == dpo_type_udp_ip4 ||
dpo->dpoi_type == dpo_type_udp_ip6)
@@ -405,11 +405,10 @@ hicn_route_enable (fib_prefix_t *prefix, hicn_face_id_t **pvec_faces)
{
HICN_DEBUG (
"No route found for %U. Creating DPO and tracking fib prefix.",
- format_ip_prefix, prefix);
+ format_fib_prefix, prefix);
dpo_id_t dpo = DPO_INVALID;
- index_t dpo_idx;
- default_dpo.hicn_dpo_create (prefix->fp_proto, 0, NEXT_HOP_INVALID,
- &dpo_idx);
+ index_t dpo_idx = ~0;
+ default_dpo.hicn_dpo_create (prefix->fp_proto, 0, 0, &dpo_idx);
HICN_DEBUG ("Created new DPO_MW_CTX_T: %d.", dpo_idx);
/* the value we got when we registered */
@@ -534,8 +533,8 @@ hicn_route_disable (fib_prefix_t *prefix)
if (fib_hicn_entry_index == FIB_NODE_INDEX_INVALID)
{
- HICN_ERROR ("Route %U not found", format_ip_prefix, prefix);
- return HICN_ERROR_ROUTE_NOT_FOUND;
+ HICN_ERROR ("Route %U not found", format_fib_prefix, prefix);
+ ret = HICN_ERROR_ROUTE_NOT_FOUND;
}
else
{
@@ -605,7 +604,7 @@ hicn_route_disable (fib_prefix_t *prefix)
HICN_DEBUG (
"Calling fib_entry_untrack and fib_table_entry_special_remove "
"for route %U.",
- format_ip_prefix, prefix);
+ format_fib_prefix, prefix);
fib_entry_untrack (hicn_fib_entry->fib_entry_index,
hicn_fib_entry->fib_sibling);