Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/140052/?format=api
http://patches.dpdk.org/api/patches/140052/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/patch/20240514091327.441533-1-daniil.ushkov@yandex.ru/", "project": { "id": 1, "url": "http://patches.dpdk.org/api/projects/1/?format=api", "name": "DPDK", "link_name": "dpdk", "list_id": "dev.dpdk.org", "list_email": "dev@dpdk.org", "web_url": "http://core.dpdk.org", "scm_url": "git://dpdk.org/dpdk", "webscm_url": "http://git.dpdk.org/dpdk", "list_archive_url": "https://inbox.dpdk.org/dev", "list_archive_url_format": "https://inbox.dpdk.org/dev/{}", "commit_url_format": "" }, "msgid": "<20240514091327.441533-1-daniil.ushkov@yandex.ru>", "list_archive_url": "https://inbox.dpdk.org/dev/20240514091327.441533-1-daniil.ushkov@yandex.ru", "date": "2024-05-14T09:13:26", "name": "[v5] This patch introduces a new flag RTE_VHOST_USER_ASYNC_CONNECT, which in combination with the flag RTE_VHOST_USER_CLIENT makes rte_vhost_driver_start connect asynchronously to the vhost server.", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": false, "hash": "1bf9795ec68e2a71a039286ca37433c8d779444c", "submitter": { "id": 3319, "url": "http://patches.dpdk.org/api/people/3319/?format=api", "name": "Daniil Ushkov", "email": "daniil.ushkov@yandex.ru" }, "delegate": { "id": 2642, "url": "http://patches.dpdk.org/api/users/2642/?format=api", "username": "mcoquelin", "first_name": "Maxime", "last_name": "Coquelin", "email": "maxime.coquelin@redhat.com" }, "mbox": "http://patches.dpdk.org/project/dpdk/patch/20240514091327.441533-1-daniil.ushkov@yandex.ru/mbox/", "series": [ { "id": 31918, "url": "http://patches.dpdk.org/api/series/31918/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=31918", "date": "2024-05-14T09:13:26", "name": "[v5] This patch introduces a new flag RTE_VHOST_USER_ASYNC_CONNECT, which in combination with the flag RTE_VHOST_USER_CLIENT makes rte_vhost_driver_start connect asynchronously to the vhost server.", "version": 5, "mbox": "http://patches.dpdk.org/series/31918/mbox/" } ], "comments": "http://patches.dpdk.org/api/patches/140052/comments/", "check": "warning", "checks": "http://patches.dpdk.org/api/patches/140052/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<dev-bounces@dpdk.org>", "X-Original-To": "patchwork@inbox.dpdk.org", "Delivered-To": "patchwork@inbox.dpdk.org", "Received": [ "from mails.dpdk.org (mails.dpdk.org [217.70.189.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id A8B0C4402A;\n\tTue, 14 May 2024 11:13:44 +0200 (CEST)", "from mails.dpdk.org (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id 75F56402E4;\n\tTue, 14 May 2024 11:13:44 +0200 (CEST)", "from forward103c.mail.yandex.net (forward103c.mail.yandex.net\n [178.154.239.214])\n by mails.dpdk.org (Postfix) with ESMTP id 2F1D6402AE\n for <dev@dpdk.org>; Tue, 14 May 2024 11:13:43 +0200 (CEST)", "from mail-nwsmtp-smtp-production-main-69.iva.yp-c.yandex.net\n (mail-nwsmtp-smtp-production-main-69.iva.yp-c.yandex.net\n [IPv6:2a02:6b8:c0c:2ca1:0:640:e017:0])\n by forward103c.mail.yandex.net (Yandex) with ESMTPS id 7165160B01;\n Tue, 14 May 2024 12:13:42 +0300 (MSK)", "by mail-nwsmtp-smtp-production-main-69.iva.yp-c.yandex.net\n (smtp/Yandex) with ESMTPSA id fDbrT669OqM0-othsPOEO;\n Tue, 14 May 2024 12:13:41 +0300" ], "X-Yandex-Fwd": "1", "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail;\n t=1715678021; bh=e8xmkRMPoXhDeQIK2OIqpKDDrpeSHSsnGOpcmNR0oic=;\n h=Message-Id:Date:In-Reply-To:Cc:Subject:References:To:From;\n b=C2VfOSOXFILJwyW/9jspmvxI+OlnJ/OOABLSRabL7kS8+Prs/azRaVkye/8y7vnbI\n z38HZ0i2uYTrYfFoMso444ZMAhqbw9XE3BnQFcw7PM5pEMMTmuHoTH15cSAu5nvA/y\n Nx1VJzdLsYRSFJEGnAPjWR+bgmS8S3zD7EyhuQkQ=", "Authentication-Results": "\n mail-nwsmtp-smtp-production-main-69.iva.yp-c.yandex.net;\n dkim=pass header.i=@yandex.ru", "From": "Daniil Ushkov <daniil.ushkov@yandex.ru>", "To": "dev@dpdk.org", "Cc": "Daniil Ushkov <daniil.ushkov@yandex.ru>,\n Maxime Coquelin <maxime.coquelin@redhat.com>,\n Chenbo Xia <chenbox@nvidia.com>", "Subject": "[PATCH v5] This patch introduces a new flag\n RTE_VHOST_USER_ASYNC_CONNECT,\n which in combination with the flag RTE_VHOST_USER_CLIENT makes\n rte_vhost_driver_start connect asynchronously to the vhost server.", "Date": "Tue, 14 May 2024 12:13:26 +0300", "Message-Id": "<20240514091327.441533-1-daniil.ushkov@yandex.ru>", "X-Mailer": "git-send-email 2.34.1", "In-Reply-To": "<20240417083835.164456-1-udav@mts.ru>", "References": "<20240417083835.164456-1-udav@mts.ru>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.29", "Precedence": "list", "List-Id": "DPDK patches and discussions <dev.dpdk.org>", "List-Unsubscribe": "<https://mails.dpdk.org/options/dev>,\n <mailto:dev-request@dpdk.org?subject=unsubscribe>", "List-Archive": "<http://mails.dpdk.org/archives/dev/>", "List-Post": "<mailto:dev@dpdk.org>", "List-Help": "<mailto:dev-request@dpdk.org?subject=help>", "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n <mailto:dev-request@dpdk.org?subject=subscribe>", "Errors-To": "dev-bounces@dpdk.org" }, "content": "Signed-off-by: Daniil Ushkov <daniil.ushkov@yandex.ru>\n---\nRerun checks.\n lib/vhost/rte_vhost.h | 1 +\n lib/vhost/socket.c | 28 ++++++++++++++++------------\n 2 files changed, 17 insertions(+), 12 deletions(-)", "diff": "diff --git a/lib/vhost/rte_vhost.h b/lib/vhost/rte_vhost.h\nindex db92f05344..b0434c4b8d 100644\n--- a/lib/vhost/rte_vhost.h\n+++ b/lib/vhost/rte_vhost.h\n@@ -41,6 +41,7 @@ extern \"C\" {\n #define RTE_VHOST_USER_ASYNC_COPY\t(1ULL << 7)\n #define RTE_VHOST_USER_NET_COMPLIANT_OL_FLAGS\t(1ULL << 8)\n #define RTE_VHOST_USER_NET_STATS_ENABLE\t(1ULL << 9)\n+#define RTE_VHOST_USER_ASYNC_CONNECT\t(1ULL << 10)\n \n /* Features. */\n #ifndef VIRTIO_NET_F_GUEST_ANNOUNCE\ndiff --git a/lib/vhost/socket.c b/lib/vhost/socket.c\nindex 96b3ab5595..c681d53abb 100644\n--- a/lib/vhost/socket.c\n+++ b/lib/vhost/socket.c\n@@ -45,6 +45,7 @@ struct vhost_user_socket {\n \tbool async_copy;\n \tbool net_compliant_ol_flags;\n \tbool stats_enabled;\n+\tbool async_connect;\n \n \t/*\n \t * The \"supported_features\" indicates the feature bits the\n@@ -533,21 +534,23 @@ vhost_user_start_client(struct vhost_user_socket *vsocket)\n \tconst char *path = vsocket->path;\n \tstruct vhost_user_reconnect *reconn;\n \n-\tret = vhost_user_connect_nonblock(vsocket->path, fd, (struct sockaddr *)&vsocket->un,\n-\t\t\t\t\t sizeof(vsocket->un));\n-\tif (ret == 0) {\n-\t\tvhost_user_add_connection(fd, vsocket);\n-\t\treturn 0;\n-\t}\n+\tif (!vsocket->async_connect || !vsocket->reconnect) {\n+\t\tret = vhost_user_connect_nonblock(vsocket->path, fd,\n+\t\t\t(struct sockaddr *)&vsocket->un, sizeof(vsocket->un));\n+\t\tif (ret == 0) {\n+\t\t\tvhost_user_add_connection(fd, vsocket);\n+\t\t\treturn 0;\n+\t\t}\n \n-\tVHOST_CONFIG_LOG(path, WARNING, \"failed to connect: %s\", strerror(errno));\n+\t\tVHOST_CONFIG_LOG(path, WARNING, \"failed to connect: %s\", strerror(errno));\n \n-\tif (ret == -2 || !vsocket->reconnect) {\n-\t\tclose(fd);\n-\t\treturn -1;\n-\t}\n+\t\tif (ret == -2 || !vsocket->reconnect) {\n+\t\t\tclose(fd);\n+\t\t\treturn -1;\n+\t\t}\n \n-\tVHOST_CONFIG_LOG(path, INFO, \"reconnecting...\");\n+\t\tVHOST_CONFIG_LOG(path, INFO, \"reconnecting...\");\n+\t}\n \treconn = malloc(sizeof(*reconn));\n \tif (reconn == NULL) {\n \t\tVHOST_CONFIG_LOG(path, ERR, \"failed to allocate memory for reconnect\");\n@@ -930,6 +933,7 @@ rte_vhost_driver_register(const char *path, uint64_t flags)\n \tvsocket->async_copy = flags & RTE_VHOST_USER_ASYNC_COPY;\n \tvsocket->net_compliant_ol_flags = flags & RTE_VHOST_USER_NET_COMPLIANT_OL_FLAGS;\n \tvsocket->stats_enabled = flags & RTE_VHOST_USER_NET_STATS_ENABLE;\n+\tvsocket->async_connect = flags & RTE_VHOST_USER_ASYNC_CONNECT;\n \tif (vsocket->is_vduse)\n \t\tvsocket->iommu_support = true;\n \telse\n", "prefixes": [ "v5" ] }{ "id": 140052, "url": "