From 6b94663b2455e212009a544ae23bb6a8c55407f8 Mon Sep 17 00:00:00 2001 From: Luca Muscariello Date: Thu, 9 Jun 2022 21:34:09 +0200 Subject: refactor(lib, hicn-light, vpp, hiperf): HICN-723 - move infra data structure into the shared lib - new packet cache using double hashing and lookup on prefix suffix - testing updates - authenticated requests using interest manifests MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Mauro Sardara Co-authored-by: Jordan Augé Co-authored-by: Michele Papalini Co-authored-by: Olivier Roques Co-authored-by: Enrico Loparco Change-Id: Iaddebfe6aa5279ea8553433b0f519578f6b9ccd9 Signed-off-by: Luca Muscariello --- hicn-plugin/src/route.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'hicn-plugin/src/route.c') diff --git a/hicn-plugin/src/route.c b/hicn-plugin/src/route.c index a84891b9a..0c96e1412 100644 --- a/hicn-plugin/src/route.c +++ b/hicn-plugin/src/route.c @@ -34,6 +34,7 @@ #include "infra.h" #include "udp_tunnels/udp_tunnel.h" #include "mapme.h" +#include "pg.h" #define FIB_SOURCE_HICN 0x04 // Right after the FIB_SOURCE_INTERFACE priority @@ -234,7 +235,7 @@ sync_hicn_fib_entry (hicn_dpo_ctx_t *fib_entry, hicn_face_id_t **pvec_faces) do \ { \ /* Careful, this adds a lock on the face if it exists */ \ - hicn_face_add (dpo, nh, sw_if, &face_id, 0); \ + hicn_face_add (dpo, nh, sw_if, &face_id); \ vec_validate (vec_faces, index); \ vec_faces[index] = face_id; \ (index)++; \ @@ -294,10 +295,15 @@ sync_hicn_fib_entry (hicn_dpo_ctx_t *fib_entry, hicn_face_id_t **pvec_faces) default: continue; } - HICN_DEBUG ("Added new UDP face: %d because of route prefix %s", + HICN_DEBUG ("Added new UDP face: %d because of route prefix %U", face_id, format_ip_prefix, &_fib_entry->fe_prefix); udp_tunnel_add_existing (dpo->dpoi_index, proto); } + else if (dpo_is_pgserver (dpo)) + { + hicnpg_server_t *pg_server = hicnpg_server_get (dpo->dpoi_index); + ADD_FACE (&pg_server->hicn_locator); + } } const hicn_dpo_vft_t *strategy_vft = hicn_dpo_get_vft (fib_entry->dpo_type); -- cgit 1.2.3-korg