get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/patches/139797/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 139797,
    "url": "https://patches.dpdk.org/api/patches/139797/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/20240502055706.112443-4-mattias.ronnblom@ericsson.com/",
    "project": {
        "id": 1,
        "url": "https://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": "<20240502055706.112443-4-mattias.ronnblom@ericsson.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20240502055706.112443-4-mattias.ronnblom@ericsson.com",
    "date": "2024-05-02T05:57:03",
    "name": "[RFC,v6,3/6] eal: add exactly-once bit access functions",
    "commit_ref": null,
    "pull_url": null,
    "state": "new",
    "archived": false,
    "hash": "9f01e1e16a42164281fff8ff518cfc2421f57be3",
    "submitter": {
        "id": 1077,
        "url": "https://patches.dpdk.org/api/people/1077/?format=api",
        "name": "Mattias Rönnblom",
        "email": "mattias.ronnblom@ericsson.com"
    },
    "delegate": {
        "id": 1,
        "url": "https://patches.dpdk.org/api/users/1/?format=api",
        "username": "tmonjalo",
        "first_name": "Thomas",
        "last_name": "Monjalon",
        "email": "thomas@monjalon.net"
    },
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/20240502055706.112443-4-mattias.ronnblom@ericsson.com/mbox/",
    "series": [
        {
            "id": 31863,
            "url": "https://patches.dpdk.org/api/series/31863/?format=api",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=31863",
            "date": "2024-05-02T05:57:00",
            "name": "Improve EAL bit operations API",
            "version": 6,
            "mbox": "https://patches.dpdk.org/series/31863/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/139797/comments/",
    "check": "pending",
    "checks": "https://patches.dpdk.org/api/patches/139797/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 BFF3243F65;\n\tThu,  2 May 2024 08:07:53 +0200 (CEST)",
            "from mails.dpdk.org (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id CEC93402E1;\n\tThu,  2 May 2024 08:07:35 +0200 (CEST)",
            "from EUR05-DB8-obe.outbound.protection.outlook.com\n (mail-db8eur05on2046.outbound.protection.outlook.com [40.107.20.46])\n by mails.dpdk.org (Postfix) with ESMTP id 41E61402C5\n for <dev@dpdk.org>; Thu,  2 May 2024 08:07:32 +0200 (CEST)",
            "from DUZPR01CA0073.eurprd01.prod.exchangelabs.com\n (2603:10a6:10:3c2::11) by AS5PR07MB9820.eurprd07.prod.outlook.com\n (2603:10a6:20b:651::5) with Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7544.26; Thu, 2 May\n 2024 06:07:31 +0000",
            "from DB5PEPF00014B9E.eurprd02.prod.outlook.com\n (2603:10a6:10:3c2:cafe::82) by DUZPR01CA0073.outlook.office365.com\n (2603:10a6:10:3c2::11) with Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7544.29 via Frontend\n Transport; Thu, 2 May 2024 06:07:30 +0000",
            "from oa.msg.ericsson.com (192.176.1.74) by\n DB5PEPF00014B9E.mail.protection.outlook.com (10.167.8.171) with Microsoft\n SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id\n 15.20.7544.18 via Frontend Transport; Thu, 2 May 2024 06:07:30 +0000",
            "from seliicinfr00049.seli.gic.ericsson.se (153.88.142.248) by\n smtp-central.internal.ericsson.com (100.87.178.64) with Microsoft SMTP Server\n id 15.2.1544.9; Thu, 2 May 2024 08:07:30 +0200",
            "from breslau.. (seliicwb00002.seli.gic.ericsson.se [10.156.25.100])\n by seliicinfr00049.seli.gic.ericsson.se (Postfix) with ESMTP id\n E20C5380061; Thu,  2 May 2024 08:07:29 +0200 (CEST)"
        ],
        "ARC-Seal": "i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none;\n b=WmwSslY2LfGBsbjmSEGE60YpyXYIqnjkXb54s7Qcztqx0K7vOGA/n4S1rsjP56tZXAh2nYPZsnCSt0dedkX74PRlE5B38sBUWTkc7TBtHLp1pbAkJPA9TMIztxrOHfG+W6QH5oby/BW2wc7rRvrgrKw2EYSUHew+T4AIn6C1emQlC25p14HwmAeOggdvmoc0SnKwrUbkZIN0brF2FZNae2oE5gbWNKAYVcrG9ZQee1AgMRfx0287rzMw4Zfhpsg3HrUzccP0AMehXQ19UlK3ntjBpnjbonVAV1dDgN1Si9BICyrjJ16XuTZmnkObZuxA8iK9MMCtOZI5xMJoLu1exQ==",
        "ARC-Message-Signature": "i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com;\n s=arcselector9901;\n h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1;\n bh=zmUfRKzoqHSFuLBu20WiDhlgo8uRunsquRSfzUxzP2M=;\n b=KWKKMrHP6XtwQ56Jr61NzqtfGtzDOuFKwyKgLcGEeg3jvszl1s2CJCOwT03j16ghy0o25DImu6FTn/OQGd+tg4xDRgxYg96BenoIhKNQzI9hOfOZZSNEFsCPYGFmfRQ8APjEm3cCWBMGEJC3Nqi3k4fEqwy2SjVZAzrsyWZZQTtA8I/crisl4VYrl/LrQjeelk7qg1tv7o6dWyCWYnEOSKKlRGKKxRyp3DaeN2mfzY0GXkQCFCSykExXOBOdxvkt/qj6l2/GGgCdJwwk9jPF2PYdwUaocN0PN88ElHqcXNP91afEg8CzkpmOcb2+8WhRFYn3poxr77OGRbU5AfhOog==",
        "ARC-Authentication-Results": "i=1; mx.microsoft.com 1; spf=pass (sender ip is\n 192.176.1.74) smtp.rcpttodomain=dpdk.org smtp.mailfrom=ericsson.com;\n dmarc=pass (p=reject sp=reject pct=100) action=none header.from=ericsson.com;\n dkim=none (message not signed); arc=none (0)",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=ericsson.com;\n s=selector1;\n h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck;\n bh=zmUfRKzoqHSFuLBu20WiDhlgo8uRunsquRSfzUxzP2M=;\n b=SQdbOeOZZKxYYBV4yJRbpK4/c5dTMbSt1ocERu+PQgR2kfc0RqoHcy3XT6w79OC3rJHoNUT312LGf3YnvnkiF+il/T3DbxocVWtiS9Ndeolj99km2w1utzJpbZer84zyqLvcMjdLddnjIcFgxJnqT+5XFcUFzTdykRMF8z8ZgoRddiDODiUAnO9zRCju8PpZWb23JvyjWuuUO5gz1IDQ8f4KOztsFuLLZCW+rjw9eUJ30ETZx5zL8IrZDI8d1Efa3/Tryx+BDiMd8D5d6Xxz0BmZps+185oA1/bBIMut/Qn1JytFYb/ziXeV6kiaCR8HDzXEOSVkpbQRjdFO7BULgQ==",
        "X-MS-Exchange-Authentication-Results": "spf=pass (sender IP is 192.176.1.74)\n smtp.mailfrom=ericsson.com; dkim=none (message not signed)\n header.d=none;dmarc=pass action=none header.from=ericsson.com;",
        "Received-SPF": "Pass (protection.outlook.com: domain of ericsson.com designates\n 192.176.1.74 as permitted sender)\n receiver=protection.outlook.com;\n client-ip=192.176.1.74; helo=oa.msg.ericsson.com; pr=C",
        "From": "=?utf-8?q?Mattias_R=C3=B6nnblom?= <mattias.ronnblom@ericsson.com>",
        "To": "<dev@dpdk.org>",
        "CC": "<hofors@lysator.liu.se>, Heng Wang <heng.wang@ericsson.com>,\n \"Stephen Hemminger\" <stephen@networkplumber.org>,\n Tyler Retzlaff <roretzla@linux.microsoft.com>,\n =?utf-8?q?Morten_Br=C3=B8rup?= <mb@smartsharesystems.com>, =?utf-8?q?Mattia?=\n\t=?utf-8?q?s_R=C3=B6nnblom?= <mattias.ronnblom@ericsson.com>",
        "Subject": "[RFC v6 3/6] eal: add exactly-once bit access functions",
        "Date": "Thu, 2 May 2024 07:57:03 +0200",
        "Message-ID": "<20240502055706.112443-4-mattias.ronnblom@ericsson.com>",
        "X-Mailer": "git-send-email 2.34.1",
        "In-Reply-To": "<20240502055706.112443-1-mattias.ronnblom@ericsson.com>",
        "References": "<20240430120810.108928-2-mattias.ronnblom@ericsson.com>\n <20240502055706.112443-1-mattias.ronnblom@ericsson.com>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=\"UTF-8\"",
        "Content-Transfer-Encoding": "8bit",
        "X-EOPAttributedMessage": "0",
        "X-MS-PublicTrafficType": "Email",
        "X-MS-TrafficTypeDiagnostic": "DB5PEPF00014B9E:EE_|AS5PR07MB9820:EE_",
        "X-MS-Office365-Filtering-Correlation-Id": "6a0b8216-8e2b-4f67-0ea7-08dc6a6e2698",
        "X-MS-Exchange-SenderADCheck": "1",
        "X-MS-Exchange-AntiSpam-Relay": "0",
        "X-Microsoft-Antispam": "BCL:0;ARA:13230031|376005|36860700004|1800799015;",
        "X-Microsoft-Antispam-Message-Info": "=?utf-8?q?i5aRxRCKuh0wYBXB5Y4UQRDNPy+CP/U?=\n\t=?utf-8?q?lmJWdHNj8atKoKqobtZAI26rUEPt/JltWWCe9OKTGW+ECiDKnPYB9PsjD7pSTkWYh?=\n\t=?utf-8?q?tU3WT0fU2aaHv9Dsn72tcLO1jws2Ho7BmLjEQlRxaQ6BH+wbbApSk8JNdjDQKqyos?=\n\t=?utf-8?q?oiEEhhVadFnTnsuyetWPyQXcOs3PrluGajXss9wBFZ4I5t7jpx7SElq/zEXprlTkZ?=\n\t=?utf-8?q?w4+SBJ5rZgJwWQEfQX7RMAGK8EWogrYHT5ygAaGbsi+jFV14SRuZ6R7Kqum3oXaqb?=\n\t=?utf-8?q?69WIMlemcln7IzPFO3xiZs9c8NcNuXhn+ejFoVr0xOs9bAKyCe9j6g03vKno60l0Z?=\n\t=?utf-8?q?SKgeovcGMAMtx/rkLMqa4SvkwBFfW4IlnRMEzU0Lp2G3KJaUismt+7H3nOFe4UT+x?=\n\t=?utf-8?q?mMfTHx72BZoHCWT3JbTqwkCycfcuK+CSxqgd0LQ54IDtrtRi5MlBl5zM0QLCuvcBY?=\n\t=?utf-8?q?hO7xCIrdViDlJNqV6HJp7skAoyZ1/ZFwvXSxR/9hMCLC8Hfrc7OWU4TM+SR0aPrnz?=\n\t=?utf-8?q?KlFlCoTaP4PM5mmc8rw8u9eCo/zQ4aoVyor2220kQa8Z03RRQSFM5ahK4uaM+C/Kp?=\n\t=?utf-8?q?I6o65zLfX8228I0/4WxLOj7s+VTlD0yIziLmDNYynCECjmf8d57mdKarp3WTBmmbf?=\n\t=?utf-8?q?Rk/Cs/Bh4/EaRrDTjDRDizJqjaarVOkdJPQsKunTn9U725/r0fNVjDxj3zc6q2frG?=\n\t=?utf-8?q?xzW2zwK4+4c9v5KKu77sY9eVR7HMWXj/j+F0Uzx+XI2rDZKDd2OZKp4Uknm8GHTJQ?=\n\t=?utf-8?q?io2zUG/lXFSa/li4cIU0dkKw/xm45mdYSNJQ8q7LrpcsE9NRVr5sWPo3uSC+jsJ1P?=\n\t=?utf-8?q?hmG2VrDDCyAR+JIaIVqDyU8aKhAhvpuRP6E+ZlwCEIoLBpcsoRuv46TerzHfhe5AV?=\n\t=?utf-8?q?X98UbDw/GvGoDKwSPrzMNdJ/q1SXZ7/bxGVQV9YS9eXYTp86f8gZ+vlaTFRci5Cu5?=\n\t=?utf-8?q?O9i1Y3BiFGgi687WgH1gV44W7m5P98S3Z/H4XGYnCVnFCRXNQL5Ss9pahq9eHaRue?=\n\t=?utf-8?q?2xj1972McS0ltwVob+u2fapLS7mUoVq7UQrA2nlLBN3I/cmOWqdkKpSUAnk77+in3?=\n\t=?utf-8?q?+D4rmNMID9lTPCnNsx77c2MKcjYzZ5l9lq7QjaB+H+wA7Fh4mGaF8PjNwE2bH7ARX?=\n\t=?utf-8?q?6aqMqjpSu+nrXGjOnWo0/OXTlWR040S6Ed5CCU01aJruFMkozCCyGRBngqwlr6Amo?=\n\t=?utf-8?q?sSCXofFHU4ttGMXJfo75QkHJ5Ja5mmSG0oDhgRAjGACOG9FbluJvdB75tA35iqvSf?=\n\t=?utf-8?q?2LSrMhhSGUcVUHAVYfyERzMwqALJuJ9DNEPOzKKqUyfh3DoOvs1C03EI5caTHZwdT?=\n\t=?utf-8?q?JqS54mNcA6Cr?=",
        "X-Forefront-Antispam-Report": "CIP:192.176.1.74; CTRY:SE; LANG:en; SCL:1; SRV:;\n IPV:NLI; SFV:NSPM; H:oa.msg.ericsson.com; PTR:office365.se.ericsson.net;\n CAT:NONE; SFS:(13230031)(376005)(36860700004)(1800799015); DIR:OUT; SFP:1101;",
        "X-OriginatorOrg": "ericsson.com",
        "X-MS-Exchange-CrossTenant-OriginalArrivalTime": "02 May 2024 06:07:30.5432 (UTC)",
        "X-MS-Exchange-CrossTenant-Network-Message-Id": "\n 6a0b8216-8e2b-4f67-0ea7-08dc6a6e2698",
        "X-MS-Exchange-CrossTenant-Id": "92e84ceb-fbfd-47ab-be52-080c6b87953f",
        "X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp": "\n TenantId=92e84ceb-fbfd-47ab-be52-080c6b87953f; Ip=[192.176.1.74];\n Helo=[oa.msg.ericsson.com]",
        "X-MS-Exchange-CrossTenant-AuthSource": "\n DB5PEPF00014B9E.eurprd02.prod.outlook.com",
        "X-MS-Exchange-CrossTenant-AuthAs": "Anonymous",
        "X-MS-Exchange-CrossTenant-FromEntityHeader": "HybridOnPrem",
        "X-MS-Exchange-Transport-CrossTenantHeadersStamped": "AS5PR07MB9820",
        "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": "Add test/set/clear/assign/flip functions which prevents certain\ncompiler optimizations and guarantees that program-level memory loads\nand/or stores will actually occur.\n\nThese functions are useful when interacting with memory-mapped\nhardware devices.\n\nThe \"once\" family of functions does not promise atomicity and provides\nno memory ordering guarantees beyond the C11 relaxed memory model.\n\nRFC v6:\n * Have rte_bit_once_test() accept const-marked bitsets.\n\nRFC v3:\n * Work around lack of C++ support for _Generic (Tyler Retzlaff).\n\nSigned-off-by: Mattias Rönnblom <mattias.ronnblom@ericsson.com>\nAcked-by: Morten Brørup <mb@smartsharesystems.com>\nAcked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>\n---\n lib/eal/include/rte_bitops.h | 197 +++++++++++++++++++++++++++++++++++\n 1 file changed, 197 insertions(+)",
    "diff": "diff --git a/lib/eal/include/rte_bitops.h b/lib/eal/include/rte_bitops.h\nindex 3297133e22..caec4f36bb 100644\n--- a/lib/eal/include/rte_bitops.h\n+++ b/lib/eal/include/rte_bitops.h\n@@ -226,6 +226,179 @@ extern \"C\" {\n \t\t uint32_t *: __rte_bit_flip32,\t\t\t\t\\\n \t\t uint64_t *: __rte_bit_flip64)(addr, nr)\n \n+/**\n+ * @warning\n+ * @b EXPERIMENTAL: this API may change without prior notice.\n+ *\n+ * Generic selection macro to test exactly once the value of a bit in\n+ * a 32-bit or 64-bit word. The type of operation depends on the type\n+ * of the @c addr parameter.\n+ *\n+ * This function is guaranteed to result in exactly one memory load\n+ * (e.g., it may not be eliminate or merged by the compiler).\n+ *\n+ * \\code{.c}\n+ * rte_bit_once_set(addr, 17);\n+ * if (rte_bit_once_test(addr, 17)) {\n+ *     ...\n+ * }\n+ * \\endcode\n+ *\n+ * In the above example, rte_bit_once_set() may not be removed by\n+ * the compiler, which would be allowed in case rte_bit_set() and\n+ * rte_bit_test() was used.\n+ *\n+ * \\code{.c}\n+ * while (rte_bit_once_test(addr, 17);\n+ *     ;\n+ * \\endcode\n+ *\n+ * In case rte_bit_test(addr, 17) was used instead, the resulting\n+ * object code could (and in many cases would be) replaced with\n+ * the equivalent to\n+ * \\code{.c}\n+ * if (rte_bit_test(addr, 17)) {\n+ *   for (;;) // spin forever\n+ *       ;\n+ * }\n+ * \\endcode\n+ *\n+ * rte_bit_once_test() does not give any guarantees in regards to\n+ * memory ordering or atomicity.\n+ *\n+ * The regular bit set operations (e.g., rte_bit_test()) should be\n+ * preferred over the \"once\" family of operations (e.g.,\n+ * rte_bit_once_test()) if possible, since the latter may prevent\n+ * optimizations crucial for run-time performance.\n+ *\n+ * @param addr\n+ *   A pointer to the word to query.\n+ * @param nr\n+ *   The index of the bit.\n+ * @return\n+ *   Returns true if the bit is set, and false otherwise.\n+ */\n+\n+#define rte_bit_once_test(addr, nr)\t\t\t\t\t\\\n+\t_Generic((addr),\t\t\t\t\t\t\\\n+\t\tuint32_t *: __rte_bit_once_test32,\t\t\t\\\n+\t\tconst uint32_t *: __rte_bit_once_test32,\t\t\\\n+\t\tuint64_t *: __rte_bit_once_test64,\t\t\t\\\n+\t\tconst uint64_t *: __rte_bit_once_test64)(addr, nr)\n+\n+/**\n+ * @warning\n+ * @b EXPERIMENTAL: this API may change without prior notice.\n+ *\n+ * Set bit in word exactly once.\n+ *\n+ * Set bit specified by @c nr in the word pointed to by @c addr to '1'\n+ * exactly once.\n+ *\n+ * This function is guaranteed to result in exactly one memory load\n+ * and exactly one memory store, *or* an atomic bit set operation.\n+ *\n+ * See rte_bit_test_once32() for more information and uses cases for\n+ * the \"once\" class of functions.\n+ *\n+ * This macro does not give any guarantees in regards to memory\n+ * ordering or atomicity.\n+ *\n+ * @param addr\n+ *   A pointer to the word to modify.\n+ * @param nr\n+ *   The index of the bit.\n+ */\n+\n+#define rte_bit_once_set(addr, nr)\t\t\t\t\\\n+\t_Generic((addr),\t\t\t\t\t\\\n+\t\t uint32_t *: __rte_bit_once_set32,\t\t\\\n+\t\t uint64_t *: __rte_bit_once_set64)(addr, nr)\n+\n+/**\n+ * @warning\n+ * @b EXPERIMENTAL: this API may change without prior notice.\n+ *\n+ * Clear bit in word exactly once.\n+ *\n+ * Set bit specified by @c nr in the word pointed to by @c addr to '0'\n+ * exactly once.\n+ *\n+ * This function is guaranteed to result in exactly one memory load\n+ * and exactly one memory store, *or* an atomic bit clear operation.\n+ *\n+ * See rte_bit_test_once32() for more information and uses cases for\n+ * the \"once\" class of functions.\n+ *\n+ * This macro does not give any guarantees in regards to memory\n+ * ordering or atomicity.\n+ *\n+ * @param addr\n+ *   A pointer to the word to modify.\n+ * @param nr\n+ *   The index of the bit.\n+ */\n+#define rte_bit_once_clear(addr, nr)\t\t\t\t\\\n+\t_Generic((addr),\t\t\t\t\t\\\n+\t\t uint32_t *: __rte_bit_once_clear32,\t\t\\\n+\t\t uint64_t *: __rte_bit_once_clear64)(addr, nr)\n+\n+/**\n+ * @warning\n+ * @b EXPERIMENTAL: this API may change without prior notice.\n+ *\n+ * Assign a value to bit in a word exactly once.\n+ *\n+ * Set bit specified by @c nr in the word pointed to by @c addr to the\n+ * value indicated by @c value exactly once.\n+ *\n+ * This function is guaranteed to result in exactly one memory load\n+ * and exactly one memory store, *or* an atomic bit clear operation.\n+ *\n+ * This function does not give any guarantees in regards to memory\n+ * ordering or atomicity.\n+ *\n+ * @param addr\n+ *   A pointer to the word to modify.\n+ * @param nr\n+ *   The index of the bit.\n+ * @param value\n+ *   The new value of the bit - true for '1', or false for '0'.\n+ */\n+#define rte_bit_once_assign(addr, nr, value)\t\t\t\t\\\n+\t_Generic((addr),\t\t\t\t\t\t\\\n+\t\t uint32_t *: __rte_bit_once_assign32,\t\t\t\\\n+\t\t uint64_t *: __rte_bit_once_assign64)(addr, nr, value)\n+\n+/**\n+ * @warning\n+ * @b EXPERIMENTAL: this API may change without prior notice.\n+ *\n+ * Flip bit in word, reading and writing exactly once.\n+ *\n+ * Change the value of a bit to '0' if '1' or '1' if '0' in a 32-bit\n+ * or 64-bit word. The type of operation depends on the type of the @c\n+ * addr parameter.\n+ *\n+ * This function is guaranteed to result in exactly one memory load\n+ * and exactly one memory store, *or* an atomic bit flip operation.\n+ *\n+ * See rte_bit_test_once32() for more information and uses cases for\n+ * the \"once\" class of functions.\n+ *\n+ * This macro does not give any guarantees in regards to memory\n+ * ordering or atomicity.\n+ *\n+ * @param addr\n+ *   A pointer to the word to modify.\n+ * @param nr\n+ *   The index of the bit.\n+ */\n+#define rte_bit_once_flip(addr, nr)\t\t\t\t\\\n+\t_Generic((addr),\t\t\t\t\t\\\n+\t\t uint32_t *: __rte_bit_once_flip32,\t\t\\\n+\t\t uint64_t *: __rte_bit_once_flip64)(addr, nr)\n+\n #define __RTE_GEN_BIT_TEST(family, fun, qualifier, size)\t\t\\\n \t__rte_experimental\t\t\t\t\t\t\\\n \tstatic inline bool\t\t\t\t\t\t\\\n@@ -298,6 +471,18 @@ __RTE_GEN_BIT_CLEAR(, clear,, 64)\n __RTE_GEN_BIT_ASSIGN(, assign,, 64)\n __RTE_GEN_BIT_FLIP(, flip,, 64)\n \n+__RTE_GEN_BIT_TEST(once_, test, volatile, 32)\n+__RTE_GEN_BIT_SET(once_, set, volatile, 32)\n+__RTE_GEN_BIT_CLEAR(once_, clear, volatile, 32)\n+__RTE_GEN_BIT_ASSIGN(once_, assign, volatile, 32)\n+__RTE_GEN_BIT_FLIP(once_, flip, volatile, 32)\n+\n+__RTE_GEN_BIT_TEST(once_, test, volatile, 64)\n+__RTE_GEN_BIT_SET(once_, set, volatile, 64)\n+__RTE_GEN_BIT_CLEAR(once_, clear, volatile, 64)\n+__RTE_GEN_BIT_ASSIGN(once_, assign, volatile, 64)\n+__RTE_GEN_BIT_FLIP(once_, flip, volatile, 64)\n+\n /*------------------------ 32-bit relaxed operations ------------------------*/\n \n /**\n@@ -993,6 +1178,12 @@ rte_log2_u64(uint64_t v)\n #undef rte_bit_assign\n #undef rte_bit_flip\n \n+#undef rte_bit_once_test\n+#undef rte_bit_once_set\n+#undef rte_bit_once_clear\n+#undef rte_bit_once_assign\n+#undef rte_bit_once_flip\n+\n #define __RTE_BIT_OVERLOAD_SZ_2(fun, qualifier, size, arg1_type, arg1_name) \\\n \tstatic inline void\t\t\t\t\t\t\\\n \trte_bit_ ## fun(qualifier uint ## size ## _t *addr,\t\t\\\n@@ -1042,6 +1233,12 @@ __RTE_BIT_OVERLOAD_2(clear,, unsigned int, nr)\n __RTE_BIT_OVERLOAD_3(assign,, unsigned int, nr, bool, value)\n __RTE_BIT_OVERLOAD_2(flip,, unsigned int, nr)\n \n+__RTE_BIT_OVERLOAD_2R(once_test, const volatile, bool, unsigned int, nr)\n+__RTE_BIT_OVERLOAD_2(once_set, volatile, unsigned int, nr)\n+__RTE_BIT_OVERLOAD_2(once_clear, volatile, unsigned int, nr)\n+__RTE_BIT_OVERLOAD_3(once_assign, volatile, unsigned int, nr, bool, value)\n+__RTE_BIT_OVERLOAD_2(once_flip, volatile, unsigned int, nr)\n+\n #endif\n \n #endif /* _RTE_BITOPS_H_ */\n",
    "prefixes": [
        "RFC",
        "v6",
        "3/6"
    ]
}