Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/116656/?format=api
http://patchwork.dpdk.org/api/patches/116656/?format=api", "web_url": "http://patchwork.dpdk.org/project/dpdk/patch/1663868722-39949-2-git-send-email-nicolas.chautru@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": "<1663868722-39949-2-git-send-email-nicolas.chautru@intel.com>", "list_archive_url": "https://inbox.dpdk.org/dev/1663868722-39949-2-git-send-email-nicolas.chautru@intel.com", "date": "2022-09-22T17:45:16", "name": "[v9,1/7] bbdev: allow operation type enum for growth", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "079966b8e9e9d8789dd41e5835968cfb781bcdcc", "submitter": { "id": 1314, "url": "http://patchwork.dpdk.org/api/people/1314/?format=api", "name": "Chautru, Nicolas", "email": "nicolas.chautru@intel.com" }, "delegate": { "id": 6690, "url": "http://patchwork.dpdk.org/api/users/6690/?format=api", "username": "akhil", "first_name": "akhil", "last_name": "goyal", "email": "gakhil@marvell.com" }, "mbox": "http://patchwork.dpdk.org/project/dpdk/patch/1663868722-39949-2-git-send-email-nicolas.chautru@intel.com/mbox/", "series": [ { "id": 24785, "url": "http://patchwork.dpdk.org/api/series/24785/?format=api", "web_url": "http://patchwork.dpdk.org/project/dpdk/list/?series=24785", "date": "2022-09-22T17:45:15", "name": "bbdev changes for 22.11", "version": 9, "mbox": "http://patchwork.dpdk.org/series/24785/mbox/" } ], "comments": "http://patchwork.dpdk.org/api/patches/116656/comments/", "check": "success", "checks": "http://patchwork.dpdk.org/api/patches/116656/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 C12A0A0543;\n\tThu, 22 Sep 2022 19:46:00 +0200 (CEST)", "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id 0371340E28;\n\tThu, 22 Sep 2022 19:45:57 +0200 (CEST)", "from mga12.intel.com (mga12.intel.com [192.55.52.136])\n by mails.dpdk.org (Postfix) with ESMTP id 61FD7400D7\n for <dev@dpdk.org>; Thu, 22 Sep 2022 19:45:54 +0200 (CEST)", "from orsmga002.jf.intel.com ([10.7.209.21])\n by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 22 Sep 2022 10:45:52 -0700", "from unknown (HELO icx-npg-scs1-cp1.localdomain) ([10.233.180.245])\n by orsmga002.jf.intel.com with ESMTP; 22 Sep 2022 10:45:51 -0700" ], "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple;\n d=intel.com; i=@intel.com; q=dns/txt; s=Intel;\n t=1663868754; x=1695404754;\n h=from:to:cc:subject:date:message-id:in-reply-to: references;\n bh=SaJextWv7yQJ4iSE5XQet8VPoy2zVP1HrcOiD45MMyc=;\n b=UXgKUQZRcWNdehEiok8QLbHRKx6iwBMNN9mb38fu+/wgYJ4nB7ljzB0S\n Kp7YbVaNx7IDXnUp3Tyh09cjDc/8u9gfJ26338HNWczldLTLdIj2LkInI\n chLQLnSxPihDc/2OS2jkDS29FUDNaOJnawPzeaAma8AEIXFl1ZLjvzNYO\n MbN7zGQuhYQ79vEgSwr2UIOd+yVKOfnvM+bBveQfNq5uY6YKve7cLD7IL\n PEvIap+49wGxnk9YCMZh8oVc4+uVXtAf7sVaYTTB4HV3WUo0jwIYjn6XK\n bntFckxBbDp2ltbjfjoVtX19Dwat89QAoOOAz2ndfySUYOeOrQ9gxlTlD A==;", "X-IronPort-AV": [ "E=McAfee;i=\"6500,9779,10478\"; a=\"280099958\"", "E=Sophos;i=\"5.93,337,1654585200\"; d=\"scan'208\";a=\"280099958\"", "E=Sophos;i=\"5.93,337,1654585200\"; d=\"scan'208\";a=\"619887771\"" ], "X-ExtLoop1": "1", "From": "Nic Chautru <nicolas.chautru@intel.com>", "To": "dev@dpdk.org,\n\tthomas@monjalon.net,\n\tgakhil@marvell.com", "Cc": "maxime.coquelin@redhat.com, trix@redhat.com, mdr@ashroe.eu,\n bruce.richardson@intel.com, david.marchand@redhat.com,\n stephen@networkplumber.org, mingshan.zhang@intel.com,\n hemant.agrawal@nxp.com, Nicolas Chautru <nicolas.chautru@intel.com>", "Subject": "[PATCH v9 1/7] bbdev: allow operation type enum for growth", "Date": "Thu, 22 Sep 2022 10:45:16 -0700", "Message-Id": "<1663868722-39949-2-git-send-email-nicolas.chautru@intel.com>", "X-Mailer": "git-send-email 1.8.3.1", "In-Reply-To": "<1663868722-39949-1-git-send-email-nicolas.chautru@intel.com>", "References": "<1655491040-183649-6-git-send-email-nicolas.chautru@intel.com>\n <1663868722-39949-1-git-send-email-nicolas.chautru@intel.com>", "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": "From: Nicolas Chautru <nicolas.chautru@intel.com>\n\nUpdating the enum for rte_bbdev_op_type\nto allow to keep ABI compatible for enum insertion\nwhile adding padded maximum value for array need.\nRemoving RTE_BBDEV_OP_TYPE_COUNT and instead exposing\nRTE_BBDEV_OP_TYPE_PADDED_MAX.\n\nSigned-off-by: Nicolas Chautru <nicolas.chautru@intel.com>\nAcked-by: Maxime Coquelin <maxime.coquelin@redhat.com>\n---\n app/test-bbdev/test_bbdev.c | 2 +-\n app/test-bbdev/test_bbdev_perf.c | 4 ++--\n examples/bbdev_app/main.c | 2 +-\n lib/bbdev/rte_bbdev.c | 8 +++++---\n lib/bbdev/rte_bbdev_op.h | 2 +-\n 5 files changed, 10 insertions(+), 8 deletions(-)", "diff": "diff --git a/app/test-bbdev/test_bbdev.c b/app/test-bbdev/test_bbdev.c\nindex ac06d73..1063f6e 100644\n--- a/app/test-bbdev/test_bbdev.c\n+++ b/app/test-bbdev/test_bbdev.c\n@@ -521,7 +521,7 @@ struct bbdev_testsuite_params {\n \trte_mempool_free(mp);\n \n \tTEST_ASSERT((mp = rte_bbdev_op_pool_create(\"Test_INV\",\n-\t\t\tRTE_BBDEV_OP_TYPE_COUNT, size, cache_size, 0)) == NULL,\n+\t\t\tRTE_BBDEV_OP_TYPE_PADDED_MAX, size, cache_size, 0)) == NULL,\n \t\t\t\"Failed test for rte_bbdev_op_pool_create: \"\n \t\t\t\"returned value is not NULL for invalid type\");\n \ndiff --git a/app/test-bbdev/test_bbdev_perf.c b/app/test-bbdev/test_bbdev_perf.c\nindex fad3b1e..1abda2d 100644\n--- a/app/test-bbdev/test_bbdev_perf.c\n+++ b/app/test-bbdev/test_bbdev_perf.c\n@@ -2428,13 +2428,13 @@ typedef int (test_case_function)(struct active_device *ad,\n \n \t/* Find capabilities */\n \tconst struct rte_bbdev_op_cap *cap = info.drv.capabilities;\n-\tfor (i = 0; i < RTE_BBDEV_OP_TYPE_COUNT; i++) {\n+\tdo {\n \t\tif (cap->type == test_vector.op_type) {\n \t\t\tcapabilities = cap;\n \t\t\tbreak;\n \t\t}\n \t\tcap++;\n-\t}\n+\t} while (cap->type != RTE_BBDEV_OP_NONE);\n \tTEST_ASSERT_NOT_NULL(capabilities,\n \t\t\t\"Couldn't find capabilities\");\n \ndiff --git a/examples/bbdev_app/main.c b/examples/bbdev_app/main.c\nindex fc7e8b8..ef0ba76 100644\n--- a/examples/bbdev_app/main.c\n+++ b/examples/bbdev_app/main.c\n@@ -1041,7 +1041,7 @@ uint16_t bbdev_parse_number(const char *mask)\n \tvoid *sigret;\n \tstruct app_config_params app_params = def_app_config;\n \tstruct rte_mempool *ethdev_mbuf_mempool, *bbdev_mbuf_mempool;\n-\tstruct rte_mempool *bbdev_op_pools[RTE_BBDEV_OP_TYPE_COUNT];\n+\tstruct rte_mempool *bbdev_op_pools[RTE_BBDEV_OP_TYPE_PADDED_MAX];\n \tstruct lcore_conf lcore_conf[RTE_MAX_LCORE] = { {0} };\n \tstruct lcore_statistics lcore_stats[RTE_MAX_LCORE] = { {0} };\n \tstruct stats_lcore_params stats_lcore;\ndiff --git a/lib/bbdev/rte_bbdev.c b/lib/bbdev/rte_bbdev.c\nindex aaee7b7..4da8047 100644\n--- a/lib/bbdev/rte_bbdev.c\n+++ b/lib/bbdev/rte_bbdev.c\n@@ -23,6 +23,8 @@\n \n #define DEV_NAME \"BBDEV\"\n \n+/* Number of supported operation types */\n+#define BBDEV_OP_TYPE_COUNT 5\n \n /* BBDev library logging ID */\n RTE_LOG_REGISTER_DEFAULT(bbdev_logtype, NOTICE);\n@@ -890,10 +892,10 @@ struct rte_mempool *\n \t\treturn NULL;\n \t}\n \n-\tif (type >= RTE_BBDEV_OP_TYPE_COUNT) {\n+\tif (type >= BBDEV_OP_TYPE_COUNT) {\n \t\trte_bbdev_log(ERR,\n \t\t\t\t\"Invalid op type (%u), should be less than %u\",\n-\t\t\t\ttype, RTE_BBDEV_OP_TYPE_COUNT);\n+\t\t\t\ttype, BBDEV_OP_TYPE_COUNT);\n \t\treturn NULL;\n \t}\n \n@@ -1125,7 +1127,7 @@ struct rte_mempool *\n \t\t\"RTE_BBDEV_OP_LDPC_ENC\",\n \t};\n \n-\tif (op_type < RTE_BBDEV_OP_TYPE_COUNT)\n+\tif (op_type < BBDEV_OP_TYPE_COUNT)\n \t\treturn op_types[op_type];\n \n \trte_bbdev_log(ERR, \"Invalid operation type\");\ndiff --git a/lib/bbdev/rte_bbdev_op.h b/lib/bbdev/rte_bbdev_op.h\nindex 6d56133..cd82418 100644\n--- a/lib/bbdev/rte_bbdev_op.h\n+++ b/lib/bbdev/rte_bbdev_op.h\n@@ -748,7 +748,7 @@ enum rte_bbdev_op_type {\n \tRTE_BBDEV_OP_TURBO_ENC, /**< Turbo encode */\n \tRTE_BBDEV_OP_LDPC_DEC, /**< LDPC decode */\n \tRTE_BBDEV_OP_LDPC_ENC, /**< LDPC encode */\n-\tRTE_BBDEV_OP_TYPE_COUNT, /**< Count of different op types */\n+\tRTE_BBDEV_OP_TYPE_PADDED_MAX = 8, /**< Maximum op type number including padding */\n };\n \n /** Bit indexes of possible errors reported through status field */\n", "prefixes": [ "v9", "1/7" ] }{ "id": 116656, "url": "