vmxnet3: vmxnet3_dump is broken 36/29536/2
authorSteven Luong <sluong@cisco.com>
Tue, 20 Oct 2020 00:21:10 +0000 (17:21 -0700)
committerDamjan Marion <dmarion@me.com>
Sat, 24 Oct 2020 09:40:45 +0000 (09:40 +0000)
control ping id was not set

Fixes: gerrit 22396 / I009e806997461ad790f125d6359993862e1c5e5d
Type: fix

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: I6e96533f150da4bd0e651b5572345246623ae0ad

src/plugins/vmxnet3/vmxnet3_test.c

index fbd675d..6fa9373 100644 (file)
@@ -173,6 +173,9 @@ api_vmxnet3_dump (vat_main_t * vam)
   S (mp);
 
   /* Use a control ping for synchronization */
+  if (!vxm->ping_id)
+    vxm->ping_id =
+      vl_msg_api_get_msg_index ((u8 *) (VL_API_CONTROL_PING_CRC));
   mp_ping = vl_msg_api_alloc_as_if_client (sizeof (*mp_ping));
   mp_ping->_vl_msg_id = htons (vxm->ping_id);
   mp_ping->client_index = vam->my_client_index;