avf: print queue id in packet trace 35/21435/2
authorDamjan Marion <damarion@cisco.com>
Wed, 21 Aug 2019 14:33:56 +0000 (16:33 +0200)
committerFlorin Coras <florin.coras@gmail.com>
Wed, 21 Aug 2019 15:45:54 +0000 (15:45 +0000)
Type: feature

Change-Id: If3deb26b9ee3b9e677c9dc50789bf81fe6c11dee
Signed-off-by: Damjan Marion <damarion@cisco.com>
src/plugins/avf/avf.h
src/plugins/avf/format.c
src/plugins/avf/input.c

index 4994074..1ddae66 100644 (file)
@@ -320,7 +320,8 @@ avf_rxd_is_not_dd (avf_rx_desc_t * d)
 
 typedef struct
 {
-  u32 next_index;
+  u16 qid;
+  u16 next_index;
   u32 hw_if_index;
   u64 qw1s[AVF_RX_MAX_DESC_IN_CHAIN];
 } avf_input_trace_t;
index 4def8b5..bc2b94e 100644 (file)
@@ -131,9 +131,9 @@ format_avf_input_trace (u8 * s, va_list * args)
   u32 indent = format_get_indent (s);
   int i = 0;
 
-  s = format (s, "avf: %v (%d) next-node %U",
-             hi->name, t->hw_if_index, format_vlib_next_node_name, vm,
-             node->index, t->next_index);
+  s = format (s, "avf: %v (%d) qid %u next-node %U",
+             hi->name, t->hw_if_index, t->qid, format_vlib_next_node_name,
+             vm, node->index, t->next_index);
 
   do
     {
index fcc5518..d6dda6c 100644 (file)
@@ -396,6 +396,7 @@ no_more_desc:
          vlib_trace_buffer (vm, node, next_index, b, /* follow_chain */ 0);
          tr = vlib_add_trace (vm, node, b, sizeof (*tr));
          tr->next_index = next_index;
+         tr->qid = qid;
          tr->hw_if_index = ad->hw_if_index;
          tr->qw1s[0] = ptd->qw1s[i];
          for (j = 1; j < AVF_RX_MAX_DESC_IN_CHAIN; j++)