Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/124243/?format=api
http://patches.dpdk.org/api/patches/124243/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/patch/20230220233556.168553-21-stephen@networkplumber.org/", "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": "<20230220233556.168553-21-stephen@networkplumber.org>", "list_archive_url": "https://inbox.dpdk.org/dev/20230220233556.168553-21-stephen@networkplumber.org", "date": "2023-02-20T23:35:54", "name": "[v8,20/22] hash: move rte_thash_gfni stubs out of header file", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "6060e4bb0cbb362d8d6ea3918b145e13d2c63c0c", "submitter": { "id": 27, "url": "http://patches.dpdk.org/api/people/27/?format=api", "name": "Stephen Hemminger", "email": "stephen@networkplumber.org" }, "delegate": { "id": 1, "url": "http://patches.dpdk.org/api/users/1/?format=api", "username": "tmonjalo", "first_name": "Thomas", "last_name": "Monjalon", "email": "thomas@monjalon.net" }, "mbox": "http://patches.dpdk.org/project/dpdk/patch/20230220233556.168553-21-stephen@networkplumber.org/mbox/", "series": [ { "id": 27098, "url": "http://patches.dpdk.org/api/series/27098/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=27098", "date": "2023-02-20T23:35:34", "name": "Convert static logtypes in libraries", "version": 8, "mbox": "http://patches.dpdk.org/series/27098/mbox/" } ], "comments": "http://patches.dpdk.org/api/patches/124243/comments/", "check": "success", "checks": "http://patches.dpdk.org/api/patches/124243/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 1E88A41CF1;\n\tTue, 21 Feb 2023 00:37:58 +0100 (CET)", "from mails.dpdk.org (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id 5B9BC43179;\n\tTue, 21 Feb 2023 00:36:36 +0100 (CET)", "from mail-pf1-f176.google.com (mail-pf1-f176.google.com\n [209.85.210.176])\n by mails.dpdk.org (Postfix) with ESMTP id 3142B43141\n for <dev@dpdk.org>; Tue, 21 Feb 2023 00:36:17 +0100 (CET)", "by mail-pf1-f176.google.com with SMTP id fd25so599668pfb.1\n for <dev@dpdk.org>; Mon, 20 Feb 2023 15:36:17 -0800 (PST)", "from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218])\n by smtp.gmail.com with ESMTPSA id\n q19-20020a62e113000000b005a8dc935ec1sm8215908pfh.62.2023.02.20.15.36.15\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Mon, 20 Feb 2023 15:36:15 -0800 (PST)" ], "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=networkplumber-org.20210112.gappssmtp.com; s=20210112;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:from:to:cc:subject:date\n :message-id:reply-to;\n bh=dGm9hn4jY/wq6ATDlBoMznoK+SGsfKps427n+SePoU8=;\n b=vBkc4YJNUrlP1wsMTIgrmdYDirgd14vI7/3Q3i10dh0ATeoC9Vs8Rn3XMfJ8l4RCOX\n /pMCa0D1L960gu7WE190ADnu8ZLQzu2K2uo8XnLISC4caFR6/wy1qW9Z18JkKPAFJsLE\n 1KuFk+HQZ0T+juMoaUkExpfUGuONw0kBgvaNyh9C50oJmVHW7fA/9MOwlLNdX9CEeze+\n cLQ8ohVnjzD/k65Mzzfj54ef0YMZBaE7Qtq3ZtVwY5GLtW/wkdGhN+VkNBD4p6mMqVGx\n DrsugRlViUWMhci9JXEGEuib8mAiPSV4MM8ytpr3ei1eooAzLLYa1pSfOkgXYArDxwco\n VeRQ==", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20210112;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc\n :subject:date:message-id:reply-to;\n bh=dGm9hn4jY/wq6ATDlBoMznoK+SGsfKps427n+SePoU8=;\n b=uK0BM5LVFzGbDy81Q8tuc0kzbzjEKkTOG011ipvxiSkvC95B/1Poag8rPF0Bo9YYf/\n kaefcHksyPnJhGUcUVm3WuE/4CwS+Vt7YTWuA49RLuOeAl/TLB6GDsAMFqoeIwv9cI2p\n 2XhqDS9vETDpVEqDFh5AworI0PS7CYlWLsx1p8MalZeTSjTIeE4VrgehfyHZeuMR7Ti0\n Uo4Q3DGEvi26wEoHJlKb63xerJlmhW0zSyKq766j3WeR0le5epTeuoXAN6bqXQypHs0n\n 1EOnN2Etg0Z6HuFjjEE7Rt83G6G9PLG4mLCt0PT3zVgiMSb3C0DzShxDckv/+4zoHhuD\n S2zQ==", "X-Gm-Message-State": "AO0yUKVPMknoXtYZFjVJtUq8uTgDPftQjF6au7VCoSDBcOYdzO6CGqXD\n TOKJAo6fqyemWAy9iJudqgXy3vLeQ/smqEde1dM=", "X-Google-Smtp-Source": "\n AK7set94BBxMJqRFJTZNnZ3MYMEq1nJXHjppdeYa8jr2v2PLejzGA27NE0LOlsG6H1SlrtE5C0lPug==", "X-Received": "by 2002:a62:1d4e:0:b0:5a8:cec9:6ab6 with SMTP id\n d75-20020a621d4e000000b005a8cec96ab6mr2999980pfd.31.1676936176410;\n Mon, 20 Feb 2023 15:36:16 -0800 (PST)", "From": "Stephen Hemminger <stephen@networkplumber.org>", "To": "dev@dpdk.org", "Cc": "Stephen Hemminger <stephen@networkplumber.org>", "Subject": "[PATCH v8 20/22] hash: move rte_thash_gfni stubs out of header file", "Date": "Mon, 20 Feb 2023 15:35:54 -0800", "Message-Id": "<20230220233556.168553-21-stephen@networkplumber.org>", "X-Mailer": "git-send-email 2.39.1", "In-Reply-To": "<20230220233556.168553-1-stephen@networkplumber.org>", "References": "<20230207204151.1503491-1-stephen@networkplumber.org>\n <20230220233556.168553-1-stephen@networkplumber.org>", "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": "Having stubs in header file makes it harder to update\nRTE_LOG(). Also modify to only print warning once.\n\nSigned-off-by: Stephen Hemminger <stephen@networkplumber.org>\n---\n lib/hash/meson.build | 8 +++++++-\n lib/hash/rte_thash_gfni.c | 43 +++++++++++++++++++++++++++++++++++++++\n lib/hash/rte_thash_gfni.h | 28 +++++--------------------\n lib/hash/version.map | 4 ++++\n 4 files changed, 59 insertions(+), 24 deletions(-)\n create mode 100644 lib/hash/rte_thash_gfni.c", "diff": "diff --git a/lib/hash/meson.build b/lib/hash/meson.build\nindex 2f757d45f9bc..e56ee8572564 100644\n--- a/lib/hash/meson.build\n+++ b/lib/hash/meson.build\n@@ -17,7 +17,13 @@ indirect_headers += files(\n 'rte_thash_x86_gfni.h',\n )\n \n-sources = files('rte_cuckoo_hash.c', 'rte_fbk_hash.c', 'rte_thash.c')\n+sources = files(\n+ 'rte_cuckoo_hash.c',\n+ 'rte_fbk_hash.c',\n+ 'rte_thash.c',\n+ 'rte_thash_gfni.c'\n+)\n+\n deps += ['net']\n deps += ['ring']\n deps += ['rcu']\ndiff --git a/lib/hash/rte_thash_gfni.c b/lib/hash/rte_thash_gfni.c\nnew file mode 100644\nindex 000000000000..7617b9d4f630\n--- /dev/null\n+++ b/lib/hash/rte_thash_gfni.c\n@@ -0,0 +1,43 @@\n+/* SPDX-License-Identifier: BSD-3-Clause\n+ * Copyright(c) 2021 Intel Corporation\n+ */\n+\n+#include <stdbool.h>\n+\n+#include <rte_compat.h>\n+#include <rte_log.h>\n+#include <rte_thash_gfni.h>\n+\n+uint32_t\n+rte_thash_gfni(const uint64_t *mtrx __rte_unused,\n+\t const uint8_t *key __rte_unused, int len __rte_unused)\n+{\n+\tstatic bool warned;\n+\n+\tif (!warned) {\n+\t\twarned = true;\n+\t\tRTE_LOG(ERR, HASH,\n+\t\t\t\"%s is undefined under given arch\\n\", __func__);\n+\t}\n+\n+\treturn 0;\n+}\n+\n+void\n+rte_thash_gfni_bulk(const uint64_t *mtrx __rte_unused,\n+\t\t int len __rte_unused, uint8_t *tuple[] __rte_unused,\n+\t\t uint32_t val[], uint32_t num)\n+{\n+\tunsigned int i;\n+\n+\tstatic bool warned;\n+\n+\tif (!warned) {\n+\t\twarned = true;\n+\t\tRTE_LOG(ERR, HASH,\n+\t\t\t\"%s is undefined under given arch\\n\", __func__);\n+\t}\n+\n+\tfor (i = 0; i < num; i++)\n+\t\tval[i] = 0;\n+}\ndiff --git a/lib/hash/rte_thash_gfni.h b/lib/hash/rte_thash_gfni.h\nindex ef90faa302d1..86208eb45ebb 100644\n--- a/lib/hash/rte_thash_gfni.h\n+++ b/lib/hash/rte_thash_gfni.h\n@@ -9,13 +9,8 @@\n extern \"C\" {\n #endif\n \n-#include <rte_compat.h>\n-#include <rte_log.h>\n-\n #ifdef RTE_ARCH_X86\n-\n #include <rte_thash_x86_gfni.h>\n-\n #endif\n \n #ifndef RTE_THASH_GFNI_DEFINED\n@@ -38,13 +33,8 @@ extern \"C\" {\n * Calculated Toeplitz hash value.\n */\n __rte_experimental\n-static inline uint32_t\n-rte_thash_gfni(const uint64_t *mtrx __rte_unused,\n-\tconst uint8_t *key __rte_unused, int len __rte_unused)\n-{\n-\tRTE_LOG(ERR, HASH, \"%s is undefined under given arch\\n\", __func__);\n-\treturn 0;\n-}\n+uint32_t\n+rte_thash_gfni(const uint64_t *mtrx, const uint8_t *key, int len);\n \n /**\n * Bulk implementation for Toeplitz hash.\n@@ -67,17 +57,9 @@ rte_thash_gfni(const uint64_t *mtrx __rte_unused,\n * Number of tuples to hash.\n */\n __rte_experimental\n-static inline void\n-rte_thash_gfni_bulk(const uint64_t *mtrx __rte_unused,\n-\tint len __rte_unused, uint8_t *tuple[] __rte_unused,\n-\tuint32_t val[], uint32_t num)\n-{\n-\tunsigned int i;\n-\n-\tRTE_LOG(ERR, HASH, \"%s is undefined under given arch\\n\", __func__);\n-\tfor (i = 0; i < num; i++)\n-\t\tval[i] = 0;\n-}\n+void\n+rte_thash_gfni_bulk(const uint64_t *mtrx, int len, uint8_t *tuple[],\n+\t\t uint32_t val[], uint32_t num);\n \n #endif /* RTE_THASH_GFNI_DEFINED */\n \ndiff --git a/lib/hash/version.map b/lib/hash/version.map\nindex bdcebd19c29b..f03b047b2eec 100644\n--- a/lib/hash/version.map\n+++ b/lib/hash/version.map\n@@ -51,4 +51,8 @@ EXPERIMENTAL {\n \trte_thash_complete_matrix;\n \trte_thash_get_gfni_matrices;\n \trte_thash_gfni_supported;\n+\n+\t# added in 22.07\n+\trte_thash_gfni;\n+\trte_thash_gfni_bulk;\n };\n", "prefixes": [ "v8", "20/22" ] }{ "id": 124243, "url": "