aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/memif
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/memif')
-rw-r--r--src/plugins/memif/memif.c7
-rw-r--r--src/plugins/memif/socket.c4
2 files changed, 11 insertions, 0 deletions
diff --git a/src/plugins/memif/memif.c b/src/plugins/memif/memif.c
index dc92e7e24ad..7267ef2e000 100644
--- a/src/plugins/memif/memif.c
+++ b/src/plugins/memif/memif.c
@@ -221,6 +221,9 @@ memif_connect (memif_if_t * mif)
{
template.file_descriptor = mq->int_fd;
template.private_data = (mif->dev_instance << 16) | (i & 0xFFFF);
+ template.description = format (0, "%U rx %u int",
+ format_memif_device_name,
+ mif->dev_instance, i);
memif_file_add (&mq->int_clib_file_index, &template);
}
vnet_hw_interface_assign_rx_thread (vnm, mif->hw_if_index, i, ~0);
@@ -440,6 +443,9 @@ memif_process (vlib_main_t * vm, vlib_node_runtime_t * rt, vlib_frame_t * f)
t.file_descriptor = sock->fd;
t.private_data = mif->dev_instance;
memif_file_add (&sock->private_data, &t);
+ t.description = format (0, "%U ctl",
+ format_memif_device_name,
+ mif->dev_instance);
hash_set (msf->dev_instance_by_fd, sock->fd, mif->dev_instance);
mif->flags |= MEMIF_IF_FLAG_CONNECTING;
@@ -805,6 +811,7 @@ memif_create_if (vlib_main_t * vm, memif_create_if_args_t * args)
template.read_function = memif_conn_fd_accept_ready;
template.file_descriptor = msf->sock->fd;
template.private_data = mif->socket_file_index;
+ template.description = format (0, "memif listener %s", msf->filename);
memif_file_add (&msf->sock->private_data, &template);
}
diff --git a/src/plugins/memif/socket.c b/src/plugins/memif/socket.c
index 9aa4a2e2e90..5e14f08ac93 100644
--- a/src/plugins/memif/socket.c
+++ b/src/plugins/memif/socket.c
@@ -440,6 +440,9 @@ memif_msg_receive (memif_if_t ** mifp, clib_socket_t * sock, clib_file_t * uf)
if ((err = memif_msg_receive_init (mifp, &msg, sock, uf->private_data)))
return err;
mif = *mifp;
+ vec_reset_length (uf->description);
+ uf->description = format (uf->description, "%U ctl",
+ format_memif_device_name, mif->dev_instance);
memif_msg_enq_ack (mif);
break;
@@ -645,6 +648,7 @@ memif_conn_fd_accept_ready (clib_file_t * uf)
template.error_function = memif_master_conn_fd_error;
template.file_descriptor = client->fd;
template.private_data = uf->private_data;
+ template.description = format (0, "memif in conn on %s", msf->filename);
memif_file_add (&client->private_data, &template);