diff options
author | Michele Papalini <micpapal@cisco.com> | 2023-01-20 10:56:42 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@fd.io> | 2023-01-20 10:56:42 +0000 |
commit | 1d591ba03d2a8575bcbbbaac32af282ea533d89f (patch) | |
tree | 96571d1ee109ee7497d01a774e7d0865bff8e746 | |
parent | bbc377fa9a3519b806fef8568b7ee068c68e7879 (diff) | |
parent | 1cbb502b7bb6f9072f6a9de8f927df9f7e4e59b8 (diff) |
Merge "feat(vpp): improve tracing" into stable/2210
-rw-r--r-- | hicn-plugin/src/data_fwd.h | 1 | ||||
-rw-r--r-- | hicn-plugin/src/data_fwd_node.c | 7 |
2 files changed, 6 insertions, 2 deletions
diff --git a/hicn-plugin/src/data_fwd.h b/hicn-plugin/src/data_fwd.h index 129ca5b73..4acfdea4d 100644 --- a/hicn-plugin/src/data_fwd.h +++ b/hicn-plugin/src/data_fwd.h @@ -50,6 +50,7 @@ typedef struct u32 sw_if_index; u8 pkt_type; u8 packet_data[64]; + u32 face; } hicn_data_fwd_trace_t; typedef enum diff --git a/hicn-plugin/src/data_fwd_node.c b/hicn-plugin/src/data_fwd_node.c index 981dc2c5e..dc1510fae 100644 --- a/hicn-plugin/src/data_fwd_node.c +++ b/hicn-plugin/src/data_fwd_node.c @@ -162,6 +162,7 @@ hicn_satisfy_faces (vlib_main_t *vm, u32 bi0, hicn_pcs_entry_t *pitp, { hicn_data_fwd_trace_t *t = vlib_add_trace (vm, node, h0, sizeof (*t)); + t->face = face0; t->pkt_type = HICN_PACKET_TYPE_DATA; t->sw_if_index = vnet_buffer (h0)->sw_if_index[VLIB_RX]; t->next_index = next0; @@ -173,6 +174,7 @@ hicn_satisfy_faces (vlib_main_t *vm, u32 bi0, hicn_pcs_entry_t *pitp, { hicn_data_fwd_trace_t *t = vlib_add_trace (vm, node, h1, sizeof (*t)); + t->face = face1; t->pkt_type = HICN_PACKET_TYPE_DATA; t->sw_if_index = vnet_buffer (h1)->sw_if_index[VLIB_RX]; t->next_index = next1; @@ -212,6 +214,7 @@ hicn_satisfy_faces (vlib_main_t *vm, u32 bi0, hicn_pcs_entry_t *pitp, { hicn_data_fwd_trace_t *t = vlib_add_trace (vm, node, h0, sizeof (*t)); + t->face = face0; t->pkt_type = HICN_PACKET_TYPE_DATA; t->sw_if_index = vnet_buffer (h0)->sw_if_index[VLIB_RX]; t->next_index = next0; @@ -284,8 +287,8 @@ hicn_data_fwd_format_trace (u8 *s, va_list *args) hicn_data_fwd_trace_t *t = va_arg (*args, hicn_data_fwd_trace_t *); u32 indent = format_get_indent (s); - s = format (s, "DATAFWD: pkt: %d, sw_if_index %d, next index %d\n", - (int) t->pkt_type, t->sw_if_index, t->next_index); + s = format (s, "DATAFWD: pkt: %d, sw_if_index %d, next index %d, face %d\n", + (int) t->pkt_type, t->sw_if_index, t->next_index, t->face); s = format (s, "%U%U", format_white_space, indent, format_ip6_header, t->packet_data, sizeof (t->packet_data)); |