aboutsummaryrefslogtreecommitdiffstats
path: root/hicn-plugin/src/faces/app/face_prod.c
diff options
context:
space:
mode:
authorAlberto Compagno <acompagn+fdio@cisco.com>2019-02-19 18:46:36 +0100
committerAlberto Compagno <acompagn+fdio@cisco.com>2019-02-20 18:03:16 +0100
commit1c5106f66a6749266cb1d228eda98413c80cbf1f (patch)
tree40bd4c7c42eaabd3fd038caa8f9e2fe432f9a434 /hicn-plugin/src/faces/app/face_prod.c
parent286fd55fc0cf620747209570a32b79d97d50d9b4 (diff)
[HICN-71]
- Handling the case in which a pushed data hit an existing pit entry (created after the data has gone through the data_pcslookup_node). In this case the data packet is forwarded to the data_fwd_node - Handling the case in which the hash table (in pcs) is full and it is not possible to allocate another bucket. In this case the packet is dropped. - Copying packets whose length is less than 128B. VPP prevents to create a chain of vlib_buffer where the first, or middle, vlib_buffer are holding less then 128B. [HICN-72] - Assign a /128 subnet to the producer app face. Change-Id: I6c19d6d127774a7f59ac69ac965d4bcd6a72becc Signed-off-by: Alberto Compagno <acompagn+fdio@cisco.com>
Diffstat (limited to 'hicn-plugin/src/faces/app/face_prod.c')
-rw-r--r--hicn-plugin/src/faces/app/face_prod.c19
1 files changed, 13 insertions, 6 deletions
diff --git a/hicn-plugin/src/faces/app/face_prod.c b/hicn-plugin/src/faces/app/face_prod.c
index d06fe2ff3..834b35da9 100644
--- a/hicn-plugin/src/faces/app/face_prod.c
+++ b/hicn-plugin/src/faces/app/face_prod.c
@@ -144,6 +144,12 @@ hicn_face_prod_add (hicn_prefix_t * prefix, u32 sw_if, u32 * cs_reserved,
if_flags |= VNET_SW_INTERFACE_FLAG_ADMIN_UP;
vnet_sw_interface_set_flags (vnm, sw_if, if_flags);
+ u8 *s0;
+ s0 = format (0, "Prefix %U/%u", format_ip6_address,
+ &prefix->name, prefix->len);
+
+ vlib_cli_output (vm, "Received request for %s, swif %d\n", s0, sw_if);
+
if (ip46_address_is_zero (&prefix->name))
{
return HICN_ERROR_APPFACE_PROD_PREFIX_NULL;
@@ -204,19 +210,20 @@ hicn_face_prod_add (hicn_prefix_t * prefix, u32 sw_if, u32 * cs_reserved,
ip4_address_t app_ip4 = get_ip4_address ();
ip4_add_del_interface_address (vm,
sw_if,
- &app_ip4,
- ADDR_MGR_IP4_CONS_LEN,
- 0 /* is_del */ );
+ &app_ip4, 32, 0 /* is_del */ );
app_ip = to_ip46 ( /* isv6 */ 0, app_ip4.as_u8);
}
else
{
ip6_address_t app_ip6 = get_ip6_address ();
+ u8 *s0;
+ s0 = format (0, "Prefix %U", format_ip6_address, &app_ip6);
+
+ vlib_cli_output (vm, "Setting ip address %s\n", s0);
+
ip6_add_del_interface_address (vm,
sw_if,
- &app_ip6,
- ADDR_MGR_IP6_CONS_LEN,
- 0 /* is_del */ );
+ &app_ip6, 128, 0 /* is_del */ );
app_ip = to_ip46 ( /* isv6 */ 1, app_ip6.as_u8);
}