Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/74030/?format=api
http://patchwork.dpdk.org/api/patches/74030/?format=api", "web_url": "http://patchwork.dpdk.org/project/dpdk/patch/20200715021615.28467-1-Cheng1.jiang@intel.com/", "project": { "id": 1, "url": "http://patchwork.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": "<20200715021615.28467-1-Cheng1.jiang@intel.com>", "list_archive_url": "https://inbox.dpdk.org/dev/20200715021615.28467-1-Cheng1.jiang@intel.com", "date": "2020-07-15T02:16:15", "name": "[20.11,v2] raw/ioat: add a flag to control copying handle parameters", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "b11289a8488538c3d25e857078e7b57239faa5e8", "submitter": { "id": 1530, "url": "http://patchwork.dpdk.org/api/people/1530/?format=api", "name": "Jiang, Cheng1", "email": "Cheng1.jiang@intel.com" }, "delegate": { "id": 1, "url": "http://patchwork.dpdk.org/api/users/1/?format=api", "username": "tmonjalo", "first_name": "Thomas", "last_name": "Monjalon", "email": "thomas@monjalon.net" }, "mbox": "http://patchwork.dpdk.org/project/dpdk/patch/20200715021615.28467-1-Cheng1.jiang@intel.com/mbox/", "series": [ { "id": 11027, "url": "http://patchwork.dpdk.org/api/series/11027/?format=api", "web_url": "http://patchwork.dpdk.org/project/dpdk/list/?series=11027", "date": "2020-07-15T02:16:15", "name": "[20.11,v2] raw/ioat: add a flag to control copying handle parameters", "version": 2, "mbox": "http://patchwork.dpdk.org/series/11027/mbox/" } ], "comments": "http://patchwork.dpdk.org/api/patches/74030/comments/", "check": "success", "checks": "http://patchwork.dpdk.org/api/patches/74030/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 dpdk.org (dpdk.org [92.243.14.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id 582ECA0540;\n\tWed, 15 Jul 2020 04:23:02 +0200 (CEST)", "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 184521C19E;\n\tWed, 15 Jul 2020 04:23:01 +0200 (CEST)", "from mga01.intel.com (mga01.intel.com [192.55.52.88])\n by dpdk.org (Postfix) with ESMTP id 5E7741C10E\n for <dev@dpdk.org>; Wed, 15 Jul 2020 04:22:59 +0200 (CEST)", "from orsmga004.jf.intel.com ([10.7.209.38])\n by fmsmga101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 14 Jul 2020 19:22:58 -0700", "from dpdk_jiangcheng.sh.intel.com ([10.67.119.112])\n by orsmga004.jf.intel.com with ESMTP; 14 Jul 2020 19:22:55 -0700" ], "IronPort-SDR": [ "\n j1chX9BoN248xa4ukOhMd12mr0l1+MQkrTrjsh5GNh71xrFHUFJC3CEZDOUW11JMlZBvceDTPt\n dqNPrBsb8EDA==", "\n KSE5ozAsjfeLwOovJFQrMkkErBcASoBtYcOl7Fk92b7zblLtnjCTSKGPoxdBW1iACuYSZcD67Q\n IJwVYrnopqMw==" ], "X-IronPort-AV": [ "E=McAfee;i=\"6000,8403,9682\"; a=\"167183924\"", "E=Sophos;i=\"5.75,353,1589266800\"; d=\"scan'208\";a=\"167183924\"", "E=Sophos;i=\"5.75,353,1589266800\"; d=\"scan'208\";a=\"429966966\"" ], "X-Amp-Result": "SKIPPED(no attachment in message)", "X-Amp-File-Uploaded": "False", "X-ExtLoop1": "1", "From": "Cheng Jiang <Cheng1.jiang@intel.com>", "To": "bruce.richardson@intel.com,\n\tdev@dpdk.org", "Cc": "patrick.fu@intel.com,\n\tCheng Jiang <Cheng1.jiang@intel.com>", "Date": "Wed, 15 Jul 2020 02:16:15 +0000", "Message-Id": "<20200715021615.28467-1-Cheng1.jiang@intel.com>", "X-Mailer": "git-send-email 2.27.0", "In-Reply-To": "<20200713071519.110662-1-Cheng1.jiang@intel.com>", "References": "<20200713071519.110662-1-Cheng1.jiang@intel.com>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "Subject": "[dpdk-dev] [PATCH 20.11 v2] raw/ioat: add a flag to control copying\n\thandle parameters", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.15", "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", "Sender": "\"dev\" <dev-bounces@dpdk.org>" }, "content": "Add a flag which controls whether rte_ioat_enqueue_copy\nand rte_ioat_completed_copies function should process\nhandle parameters to improve the performance when handle\nparameters are not necessary to use. This is targeting\n20.11 release.\n\nSigned-off-by: Cheng Jiang <Cheng1.jiang@intel.com>\n---\nv2:\n* optimized the logic of some codes\n* added some comments\n---\n drivers/raw/ioat/ioat_rawdev.c | 1 +\n drivers/raw/ioat/rte_ioat_rawdev.h | 29 ++++++++++++++++++++++-------\n 2 files changed, 23 insertions(+), 7 deletions(-)\n\n--\n2.27.0", "diff": "diff --git a/drivers/raw/ioat/ioat_rawdev.c b/drivers/raw/ioat/ioat_rawdev.c\nindex 87fd088aa..d70e47d52 100644\n--- a/drivers/raw/ioat/ioat_rawdev.c\n+++ b/drivers/raw/ioat/ioat_rawdev.c\n@@ -57,6 +57,7 @@ ioat_dev_configure(const struct rte_rawdev *dev, rte_rawdev_obj_t config)\n \t\treturn -EINVAL;\n\n \tioat->ring_size = params->ring_size;\n+\tioat->hdls_disable = params->hdls_disable;\n \tif (ioat->desc_ring != NULL) {\n \t\trte_memzone_free(ioat->desc_mz);\n \t\tioat->desc_ring = NULL;\ndiff --git a/drivers/raw/ioat/rte_ioat_rawdev.h b/drivers/raw/ioat/rte_ioat_rawdev.h\nindex f765a6557..cf0e634f3 100644\n--- a/drivers/raw/ioat/rte_ioat_rawdev.h\n+++ b/drivers/raw/ioat/rte_ioat_rawdev.h\n@@ -31,10 +31,13 @@\n *\n * This structure is to be passed as the \".dev_private\" parameter when\n * calling the rte_rawdev_get_info() and rte_rawdev_configure() APIs on\n- * an ioat rawdev instance.\n+ * an ioat rawdev instance. The member hdls_disable controls if handles\n+ * need to be copied when calling the rte_ioat_enqueue_copy() and\n+ * rte_ioat_completed_copies() APIs.\n */\n struct rte_ioat_rawdev_config {\n \tunsigned short ring_size;\n+\tbool hdls_disable;\n };\n\n /**\n@@ -52,6 +55,7 @@ struct rte_ioat_rawdev {\n\n \tunsigned short ring_size;\n \tstruct rte_ioat_generic_hw_desc *desc_ring;\n+\tbool hdls_disable;\n \t__m128i *hdls; /* completion handles for returning to user */\n\n\n@@ -84,10 +88,12 @@ struct rte_ioat_rawdev {\n * The length of the data to be copied\n * @param src_hdl\n * An opaque handle for the source data, to be returned when this operation\n- * has been completed and the user polls for the completion details\n+ * has been completed and the user polls for the completion details if\n+ * hdls_disable is false\n * @param dst_hdl\n * An opaque handle for the destination data, to be returned when this\n * operation has been completed and the user polls for the completion details\n+ * if hdls_disable is false\n * @param fence\n * A flag parameter indicating that hardware should not begin to perform any\n * subsequently enqueued copy operations until after this operation has\n@@ -121,8 +127,10 @@ rte_ioat_enqueue_copy(int dev_id, phys_addr_t src, phys_addr_t dst,\n \tdesc->u.control_raw = (uint32_t)((!!fence << 4) | (!(write & 0xF)) << 3);\n \tdesc->src_addr = src;\n \tdesc->dest_addr = dst;\n+\tif (!ioat->hdls_disable)\n+\t\tioat->hdls[write] = _mm_set_epi64x((int64_t)dst_hdl,\n+\t\t\t\t\t(int64_t)src_hdl);\n\n-\tioat->hdls[write] = _mm_set_epi64x((int64_t)dst_hdl, (int64_t)src_hdl);\n \trte_prefetch0(&ioat->desc_ring[ioat->next_write & mask]);\n\n \tioat->enqueued++;\n@@ -168,9 +176,11 @@ rte_ioat_get_last_completed(struct rte_ioat_rawdev *ioat, int *error)\n /**\n * Returns details of copy operations that have been completed\n *\n- * Returns to the caller the user-provided \"handles\" for the copy operations\n- * which have been completed by the hardware, and not already returned by\n- * a previous call to this API.\n+ * If the hdls_disable is false, the function will return to the caller the\n+ * user-provided \"handles\" for the copy operations which have been completed\n+ * by the hardware, and not already returned by a previous call to this API.\n+ * If the hdls_disable is true, the max_copies will be ignored, and that the\n+ * src_hdls and dst_hdls can be NULL when calling the function.\n *\n * @param dev_id\n * The rawdev device id of the ioat instance\n@@ -205,6 +215,11 @@ rte_ioat_completed_copies(int dev_id, uint8_t max_copies,\n \t\treturn -1;\n \t}\n\n+\tif (ioat->hdls_disable) {\n+\t\tread += count;\n+\t\tgoto end;\n+\t}\n+\n \tif (count > max_copies)\n \t\tcount = max_copies;\n\n@@ -222,7 +237,7 @@ rte_ioat_completed_copies(int dev_id, uint8_t max_copies,\n \t\tsrc_hdls[i] = hdls[0];\n \t\tdst_hdls[i] = hdls[1];\n \t}\n-\n+end:\n \tioat->next_read = read;\n \tioat->completed += count;\n \treturn count;\n", "prefixes": [ "20.11", "v2" ] }{ "id": 74030, "url": "