vhost: log socket path on adding connection
authorGaoxiang Liu <liugaoxiang@huawei.com>
Tue, 7 Sep 2021 00:51:27 +0000 (08:51 +0800)
committerMaxime Coquelin <maxime.coquelin@redhat.com>
Tue, 14 Sep 2021 11:21:57 +0000 (13:21 +0200)
Add log print of socket path in vhost_user_add_connection.
It's useful when adding a mass of socket connections,
because the information of every connection is clearer.

Fixes: 8f972312b8f4 ("vhost: support vhost-user")
Cc: stable@dpdk.org
Signed-off-by: Gaoxiang Liu <liugaoxiang@huawei.com>
Reviewed-by: Chenbo Xia <chenbo.xia@intel.com>
lib/vhost/socket.c

index d6f9414..c654860 100644 (file)
@@ -243,7 +243,7 @@ vhost_user_add_connection(int fd, struct vhost_user_socket *vsocket)
                        dev->async_copy = 1;
        }
 
-       VHOST_LOG_CONFIG(INFO, "new device, handle is %d\n", vid);
+       VHOST_LOG_CONFIG(INFO, "new device, handle is %d, path is %s\n", vid, vsocket->path);
 
        if (vsocket->notify_ops->new_connection) {
                ret = vsocket->notify_ops->new_connection(vid);