Cover Detail
Show a cover letter.
GET /api/covers/69218/?format=api
http://patches.dpdk.org/api/covers/69218/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/cover/20200424032159.992-1-joyce.kong@arm.com/", "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": "<20200424032159.992-1-joyce.kong@arm.com>", "list_archive_url": "https://inbox.dpdk.org/dev/20200424032159.992-1-joyce.kong@arm.com", "date": "2020-04-24T03:21:53", "name": "[v9,0/6] implement common bit operation APIs", "submitter": { "id": 970, "url": "http://patches.dpdk.org/api/people/970/?format=api", "name": "Joyce Kong", "email": "joyce.kong@arm.com" }, "mbox": "http://patches.dpdk.org/project/dpdk/cover/20200424032159.992-1-joyce.kong@arm.com/mbox/", "series": [ { "id": 9606, "url": "http://patches.dpdk.org/api/series/9606/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=9606", "date": "2020-04-24T03:21:53", "name": "implement common bit operation APIs", "version": 9, "mbox": "http://patches.dpdk.org/series/9606/mbox/" } ], "comments": "http://patches.dpdk.org/api/covers/69218/comments/", "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 249DBA00C4;\n\tFri, 24 Apr 2020 05:22:28 +0200 (CEST)", "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 061211BFE7;\n\tFri, 24 Apr 2020 05:22:28 +0200 (CEST)", "from foss.arm.com (foss.arm.com [217.140.110.172])\n by dpdk.org (Postfix) with ESMTP id 882E61BFE2\n for <dev@dpdk.org>; Fri, 24 Apr 2020 05:22:26 +0200 (CEST)", "from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14])\n by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id CBA4431B;\n Thu, 23 Apr 2020 20:22:25 -0700 (PDT)", "from net-arm-thunderx2-03.shanghai.arm.com\n (net-arm-thunderx2-03.shanghai.arm.com [10.169.41.185])\n by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 082C73F68F;\n Thu, 23 Apr 2020 20:22:19 -0700 (PDT)" ], "From": "Joyce Kong <joyce.kong@arm.com>", "To": "thomas@monjalon.net, stephen@networkplumber.org,\n david.marchand@redhat.com,\n mb@smartsharesystems.com, jerinj@marvell.com, bruce.richardson@intel.com,\n ravi1.kumar@amd.com, rmody@marvell.com, shshaikh@marvell.com,\n xuanziyang2@huawei.com, cloud.wangxiaoyun@huawei.com,\n zhouguoyang@huawei.com, honnappa.nagarahalli@arm.com, gavin.hu@arm.com,\n phil.yang@arm.com", "Cc": "nd@arm.com,\n\tdev@dpdk.org", "Date": "Fri, 24 Apr 2020 11:21:53 +0800", "Message-Id": "<20200424032159.992-1-joyce.kong@arm.com>", "X-Mailer": "git-send-email 2.17.1", "In-Reply-To": "<1571125801-45773-1-git-send-email-joyce.kong@arm.com>", "References": "<1571125801-45773-1-git-send-email-joyce.kong@arm.com>", "MIME-Version": "1.0", "Content-Type": "text/plain; charset=UTF-8", "Content-Transfer-Encoding": "8bit", "Subject": "[dpdk-dev] [PATCH v9 0/6] implement common bit operation APIs", "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": "Bitwise operation APIs are defined and used in a lot of PMDs,\nwhich caused a huge code duplication. To reduce duplication,\nthis patch consolidates them into a common API family and use\nit for all the PMDs(we started with a few selectively).\n\nv9:\n 1. Change '*addr = (*addr) | mask' to '*addr = val | mask'\n <Morten Brørup>.\n 2. Move 'rte_bitops.h' from 'device' section to 'basic'\n section in 'doxy-api-index.md'<Jerin Jacob>.\nv8:\n 1. Change 'rte_pmd_bitops.h' to 'rte_bitops.h' allowing for\n future extension into other cases other than PMD only.\n 2. Replace 'unsigned long' with 'uint32_t' to fix compling\n errors, the reason is the fact that 32-bit and 64-bit\n systems have different sized 'unsigned long', which caused\n incompatibility.\n\nv7:\n 1. Change the API's head file to 'rte_pmd_bitops.h' as a common-\n but-not-public file.\n 2. Replace C11 atomic operations with 'volatile'. As the use cases\n are limited to PMDs, a 'volatile' is sufficient.\n\nv5,v6:\n Trim 'unsigned long' in PMDs down to 'uint32_t', as on mainstream\n 64-bit OS, 'unsigned long' is 64-bit in size, but the 32-bit OS\n expects 32-bit 'unsigned long' argument.\n\nv4:\n Introduce uint32_t/uint64_t *addr when definiting bit operation\n APIs.\n\nv3:\n 1. Change the API's head file back to rte_bitops.h, then implement\n both 32-bit and 64-bit operations with and without C11 atomic\n memory ordering.\n 2. Add multi-core test case for bit operations which implemented\n with memory ordering.\n 3. Modify the doc of both APIs and test cases.\n\nv2:\n 1. Add doxygen comments for the rte bit operation API.\n 2. Add test cases for common rte bit operation API.\n 3. Change the header file to rte_io_bitops.h and the operation to\n rte_io_set_bit() etc., as the API uses barriers inside and the\n barriers are only needed for IO operations.\n 4. Use an well defined uint_NN_t type.\n\nJoyce Kong (6):\n lib/eal: implement the family of common bit operation APIs\n test/bitops: add bit operation test case\n net/axgbe: use common rte bit operation APIs instead\n net/bnx2x: use common rte bit operation APIs instead\n net/qede: use common rte bit operation APIs instead\n net/hinic: use common rte bit operation APIs instead\n\n MAINTAINERS | 5 +\n app/test/Makefile | 1 +\n app/test/autotest_data.py | 6 +\n app/test/meson.build | 2 +\n app/test/test_bitops.c | 137 +++++++++++\n doc/api/doxy-api-index.md | 7 +-\n drivers/net/axgbe/axgbe_common.h | 29 +--\n drivers/net/axgbe/axgbe_ethdev.c | 14 +-\n drivers/net/axgbe/axgbe_ethdev.h | 2 +-\n drivers/net/axgbe/axgbe_mdio.c | 15 +-\n drivers/net/bnx2x/bnx2x.c | 271 +++++++++++-----------\n drivers/net/bnx2x/bnx2x.h | 10 +-\n drivers/net/bnx2x/ecore_sp.c | 68 +++---\n drivers/net/bnx2x/ecore_sp.h | 106 ++++-----\n drivers/net/hinic/Makefile | 1 +\n drivers/net/hinic/base/hinic_compat.h | 33 +--\n drivers/net/hinic/hinic_pmd_ethdev.c | 18 +-\n drivers/net/hinic/hinic_pmd_ethdev.h | 2 +-\n drivers/net/hinic/meson.build | 2 +\n drivers/net/qede/base/bcm_osal.c | 22 +-\n drivers/net/qede/base/bcm_osal.h | 14 +-\n drivers/net/qede/base/ecore.h | 6 +-\n drivers/net/qede/base/ecore_cxt.c | 6 +-\n drivers/net/qede/base/ecore_dcbx.c | 8 +-\n drivers/net/qede/base/ecore_dev.c | 38 +--\n drivers/net/qede/base/ecore_dev_api.h | 2 +-\n drivers/net/qede/base/ecore_l2.c | 6 +-\n drivers/net/qede/base/ecore_mcp.c | 4 +-\n drivers/net/qede/base/ecore_sp_commands.c | 12 +-\n drivers/net/qede/base/ecore_spq.c | 2 +-\n drivers/net/qede/base/ecore_spq.h | 10 +-\n drivers/net/qede/qede_main.c | 4 +-\n lib/librte_eal/include/meson.build | 1 +\n lib/librte_eal/include/rte_bitops.h | 258 ++++++++++++++++++++\n 34 files changed, 723 insertions(+), 399 deletions(-)\n create mode 100644 app/test/test_bitops.c\n create mode 100644 lib/librte_eal/include/rte_bitops.h" }{ "id": 69218, "url": "