get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 125002,
    "url": "https://patches.dpdk.org/api/patches/125002/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/20230310093518.5198-13-liudongdong3@huawei.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": "<20230310093518.5198-13-liudongdong3@huawei.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20230310093518.5198-13-liudongdong3@huawei.com",
    "date": "2023-03-10T09:35:14",
    "name": "[12/16] net/hns3: save hash algo to RSS filter list node",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "7727cfede833f4d00d21d7d445dac7d926ce82b6",
    "submitter": {
        "id": 2718,
        "url": "https://patches.dpdk.org/api/people/2718/?format=api",
        "name": "Dongdong Liu",
        "email": "liudongdong3@huawei.com"
    },
    "delegate": {
        "id": 319,
        "url": "https://patches.dpdk.org/api/users/319/?format=api",
        "username": "fyigit",
        "first_name": "Ferruh",
        "last_name": "Yigit",
        "email": "ferruh.yigit@amd.com"
    },
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/20230310093518.5198-13-liudongdong3@huawei.com/mbox/",
    "series": [
        {
            "id": 27329,
            "url": "https://patches.dpdk.org/api/series/27329/?format=api",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=27329",
            "date": "2023-03-10T09:35:02",
            "name": "net/hns3: some code refactor for hns3 RSS",
            "version": 1,
            "mbox": "https://patches.dpdk.org/series/27329/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/125002/comments/",
    "check": "success",
    "checks": "https://patches.dpdk.org/api/patches/125002/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 8543541E3A;\n\tFri, 10 Mar 2023 10:37:51 +0100 (CET)",
            "from mails.dpdk.org (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id EEB1142D6D;\n\tFri, 10 Mar 2023 10:36:45 +0100 (CET)",
            "from szxga01-in.huawei.com (szxga01-in.huawei.com [45.249.212.187])\n by mails.dpdk.org (Postfix) with ESMTP id 4E12442D4B;\n Fri, 10 Mar 2023 10:36:40 +0100 (CET)",
            "from kwepemi500017.china.huawei.com (unknown [172.30.72.55])\n by szxga01-in.huawei.com (SkyGuard) with ESMTP id 4PY18C5YG3znWrf;\n Fri, 10 Mar 2023 17:33:47 +0800 (CST)",
            "from localhost.localdomain (10.28.79.22) by\n kwepemi500017.china.huawei.com (7.221.188.110) with Microsoft SMTP Server\n (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id\n 15.1.2507.21; Fri, 10 Mar 2023 17:36:38 +0800"
        ],
        "From": "Dongdong Liu <liudongdong3@huawei.com>",
        "To": "<dev@dpdk.org>, <ferruh.yigit@amd.com>, <thomas@monjalon.net>,\n <andrew.rybchenko@oktetlabs.ru>",
        "CC": "<stable@dpdk.org>, <yisen.zhuang@huawei.com>, <liudongdong3@huawei.com>,\n <lihuisong@huawei.com>",
        "Subject": "[PATCH 12/16] net/hns3: save hash algo to RSS filter list node",
        "Date": "Fri, 10 Mar 2023 17:35:14 +0800",
        "Message-ID": "<20230310093518.5198-13-liudongdong3@huawei.com>",
        "X-Mailer": "git-send-email 2.22.0",
        "In-Reply-To": "<20230310093518.5198-1-liudongdong3@huawei.com>",
        "References": "<20230310093518.5198-1-liudongdong3@huawei.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Content-Type": "text/plain",
        "X-Originating-IP": "[10.28.79.22]",
        "X-ClientProxiedBy": "dggems706-chm.china.huawei.com (10.3.19.183) To\n kwepemi500017.china.huawei.com (7.221.188.110)",
        "X-CFilter-Loop": "Reflected",
        "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: Huisong Li <lihuisong@huawei.com>\n\nSave hash algo from rte flow RSS rule to RSS filter list node\ninstead of struct hns3_rss_conf.\n\nCc: stable@dpdk.org\n\nSigned-off-by: Huisong Li <lihuisong@huawei.com>\nSigned-off-by: Dongdong Liu <liudongdong3@huawei.com>\n---\n drivers/net/hns3/hns3_flow.c | 19 ++++++++++---------\n 1 file changed, 10 insertions(+), 9 deletions(-)",
    "diff": "diff --git a/drivers/net/hns3/hns3_flow.c b/drivers/net/hns3/hns3_flow.c\nindex 3700d073b1..527874df44 100644\n--- a/drivers/net/hns3/hns3_flow.c\n+++ b/drivers/net/hns3/hns3_flow.c\n@@ -1439,7 +1439,7 @@ hns3_disable_rss(struct hns3_hw *hw)\n }\n \n static int\n-hns3_parse_rss_algorithm(struct hns3_hw *hw, enum rte_eth_hash_function func,\n+hns3_parse_rss_algorithm(struct hns3_hw *hw, struct hns3_rss_conf *rss_conf,\n \t\t\t uint8_t *hash_algo)\n {\n \tconst uint8_t hash_func_map[] = {\n@@ -1451,7 +1451,7 @@ hns3_parse_rss_algorithm(struct hns3_hw *hw, enum rte_eth_hash_function func,\n \tuint8_t key[HNS3_RSS_KEY_SIZE_MAX] = {0};\n \tint ret;\n \n-\tif (func == RTE_ETH_HASH_FUNCTION_DEFAULT) {\n+\tif (rss_conf->conf.func == RTE_ETH_HASH_FUNCTION_DEFAULT) {\n \t\tret = hns3_rss_get_algo_key(hw, hash_algo, key,\n \t\t\t\t\t    hw->rss_key_size);\n \t\tif (ret != 0) {\n@@ -1466,20 +1466,21 @@ hns3_parse_rss_algorithm(struct hns3_hw *hw, enum rte_eth_hash_function func,\n \t\t * rte_flow_hash_algo) when this rule is delivered.\n \t\t */\n \t\tif (__atomic_load_n(&hw->reset.resetting, __ATOMIC_RELAXED) &&\n-\t\t    *hash_algo != hw->rss_info.rte_flow_hash_algo)\n-\t\t\t*hash_algo = hw->rss_info.rte_flow_hash_algo;\n+\t\t    *hash_algo != rss_conf->rte_flow_hash_algo)\n+\t\t\t*hash_algo = rss_conf->rte_flow_hash_algo;\n \n \t\treturn 0;\n \t}\n \n-\t*hash_algo = hash_func_map[func];\n+\t*hash_algo = hash_func_map[rss_conf->conf.func];\n \n \treturn 0;\n }\n \n static int\n-hns3_hw_rss_hash_set(struct hns3_hw *hw, struct rte_flow_action_rss *rss_config)\n+hns3_hw_rss_hash_set(struct hns3_hw *hw, struct hns3_rss_conf *conf)\n {\n+\tstruct rte_flow_action_rss *rss_config = &conf->conf;\n \tuint8_t rss_key[HNS3_RSS_KEY_SIZE_MAX] = {0};\n \tbool use_default_key = false;\n \tuint64_t flow_types;\n@@ -1493,7 +1494,7 @@ hns3_hw_rss_hash_set(struct hns3_hw *hw, struct rte_flow_action_rss *rss_config)\n \t\tuse_default_key = true;\n \t}\n \n-\tret = hns3_parse_rss_algorithm(hw, rss_config->func, &hash_algo);\n+\tret = hns3_parse_rss_algorithm(hw, conf, &hash_algo);\n \tif (ret)\n \t\treturn ret;\n \n@@ -1502,7 +1503,7 @@ hns3_hw_rss_hash_set(struct hns3_hw *hw, struct rte_flow_action_rss *rss_config)\n \t\t\t\t    hw->rss_key_size);\n \tif (ret)\n \t\treturn ret;\n-\thw->rss_info.rte_flow_hash_algo = hash_algo;\n+\tconf->rte_flow_hash_algo = hash_algo;\n \n \t/* Filter the unsupported flow types */\n \tflow_types = rss_config->types ?\n@@ -1579,7 +1580,7 @@ hns3_config_rss_filter(struct hns3_hw *hw, struct hns3_rss_conf *conf)\n \t}\n \n \t/* Set hash algorithm and flow types by the user's config */\n-\treturn hns3_hw_rss_hash_set(hw, rss_act);\n+\treturn hns3_hw_rss_hash_set(hw, conf);\n }\n \n static int\n",
    "prefixes": [
        "12/16"
    ]
}