Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/103378/?format=api
http://patches.dpdk.org/api/patches/103378/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/patch/20211102013829.42345-4-humin29@huawei.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": "<20211102013829.42345-4-humin29@huawei.com>", "list_archive_url": "https://inbox.dpdk.org/dev/20211102013829.42345-4-humin29@huawei.com", "date": "2021-11-02T01:38:28", "name": "[3/4] net/hns3: fix lack of unregistering MP action for secondary", "commit_ref": null, "pull_url": null, "state": "accepted", "archived": true, "hash": "555af5011aa8f879892f2e17b647f525071e8008", "submitter": { "id": 1944, "url": "http://patches.dpdk.org/api/people/1944/?format=api", "name": "humin (Q)", "email": "humin29@huawei.com" }, "delegate": { "id": 319, "url": "http://patches.dpdk.org/api/users/319/?format=api", "username": "fyigit", "first_name": "Ferruh", "last_name": "Yigit", "email": "ferruh.yigit@amd.com" }, "mbox": "http://patches.dpdk.org/project/dpdk/patch/20211102013829.42345-4-humin29@huawei.com/mbox/", "series": [ { "id": 20186, "url": "http://patches.dpdk.org/api/series/20186/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=20186", "date": "2021-11-02T01:38:26", "name": "bugfix for multi process of hns3 PMD", "version": 1, "mbox": "http://patches.dpdk.org/series/20186/mbox/" } ], "comments": "http://patches.dpdk.org/api/patches/103378/comments/", "check": "success", "checks": "http://patches.dpdk.org/api/patches/103378/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 4F8C7A0C4D;\n\tTue, 2 Nov 2021 02:40:48 +0100 (CET)", "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id 6DA8C4111F;\n\tTue, 2 Nov 2021 02:40:34 +0100 (CET)", "from szxga08-in.huawei.com (szxga08-in.huawei.com [45.249.212.255])\n by mails.dpdk.org (Postfix) with ESMTP id E964D410E5\n for <dev@dpdk.org>; Tue, 2 Nov 2021 02:40:29 +0100 (CET)", "from dggeme756-chm.china.huawei.com (unknown [172.30.72.56])\n by szxga08-in.huawei.com (SkyGuard) with ESMTP id 4HjsxD6dldz1DJ5t;\n Tue, 2 Nov 2021 09:38:24 +0800 (CST)", "from localhost.localdomain (10.69.192.56) by\n dggeme756-chm.china.huawei.com (10.3.19.102) with Microsoft SMTP Server\n (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id\n 15.1.2308.15; Tue, 2 Nov 2021 09:40:27 +0800" ], "From": "\"Min Hu (Connor)\" <humin29@huawei.com>", "To": "<dev@dpdk.org>", "CC": "<ferruh.yigit@intel.com>, <thomas@monjalon.net>", "Date": "Tue, 2 Nov 2021 09:38:28 +0800", "Message-ID": "<20211102013829.42345-4-humin29@huawei.com>", "X-Mailer": "git-send-email 2.33.0", "In-Reply-To": "<20211102013829.42345-1-humin29@huawei.com>", "References": "<20211102013829.42345-1-humin29@huawei.com>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "Content-Type": "text/plain", "X-Originating-IP": "[10.69.192.56]", "X-ClientProxiedBy": "dggems701-chm.china.huawei.com (10.3.19.178) To\n dggeme756-chm.china.huawei.com (10.3.19.102)", "X-CFilter-Loop": "Reflected", "Subject": "[dpdk-dev] [PATCH 3/4] net/hns3: fix lack of unregistering MP\n action for secondary", "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", "Sender": "\"dev\" <dev-bounces@dpdk.org>" }, "content": "From: Huisong Li <lihuisong@huawei.com>\n\nThis patch fixes lack of unregistering MP action for secondary process when\nPMD is closed.\n\nFixes: 9570b1fdbdad (\"net/hns3: check multi-process action register result\")\nFixes: 23d4b61fee5d (\"net/hns3: support multiple process\")\n\nSigned-off-by: Huisong Li <lihuisong@huawei.com>\nSigned-off-by: Min Hu (Connor) <humin29@huawei.com>\n---\n drivers/net/hns3/hns3_ethdev.c | 6 ++++--\n drivers/net/hns3/hns3_ethdev_vf.c | 6 ++++--\n drivers/net/hns3/hns3_mp.c | 5 +----\n drivers/net/hns3/hns3_mp.h | 2 +-\n 4 files changed, 10 insertions(+), 9 deletions(-)", "diff": "diff --git a/drivers/net/hns3/hns3_ethdev.c b/drivers/net/hns3/hns3_ethdev.c\nindex 658baf9ec3..96ab0c4f6c 100644\n--- a/drivers/net/hns3/hns3_ethdev.c\n+++ b/drivers/net/hns3/hns3_ethdev.c\n@@ -5851,6 +5851,7 @@ hns3_dev_close(struct rte_eth_dev *eth_dev)\n \n \tif (rte_eal_process_type() != RTE_PROC_PRIMARY) {\n \t\t__atomic_fetch_sub(&hw->secondary_cnt, 1, __ATOMIC_RELAXED);\n+\t\thns3_mp_uninit();\n \t\treturn 0;\n \t}\n \n@@ -5867,7 +5868,7 @@ hns3_dev_close(struct rte_eth_dev *eth_dev)\n \thns3_uninit_pf(eth_dev);\n \thns3_free_all_queues(eth_dev);\n \trte_free(hw->reset.wait_data);\n-\thns3_mp_uninit_primary();\n+\thns3_mp_uninit();\n \thns3_warn(hw, \"Close port %u finished\", hw->data->port_id);\n \n \treturn ret;\n@@ -7462,7 +7463,7 @@ hns3_dev_init(struct rte_eth_dev *eth_dev)\n \trte_free(hw->reset.wait_data);\n \n err_init_reset:\n-\thns3_mp_uninit_primary();\n+\thns3_mp_uninit();\n \n err_mp_init_primary:\n err_mp_init_secondary:\n@@ -7485,6 +7486,7 @@ hns3_dev_uninit(struct rte_eth_dev *eth_dev)\n \n \tif (rte_eal_process_type() != RTE_PROC_PRIMARY) {\n \t\t__atomic_fetch_sub(&hw->secondary_cnt, 1, __ATOMIC_RELAXED);\n+\t\thns3_mp_uninit();\n \t\treturn 0;\n \t}\n \ndiff --git a/drivers/net/hns3/hns3_ethdev_vf.c b/drivers/net/hns3/hns3_ethdev_vf.c\nindex 7286a858a9..633201a2c2 100644\n--- a/drivers/net/hns3/hns3_ethdev_vf.c\n+++ b/drivers/net/hns3/hns3_ethdev_vf.c\n@@ -1894,6 +1894,7 @@ hns3vf_dev_close(struct rte_eth_dev *eth_dev)\n \n \tif (rte_eal_process_type() != RTE_PROC_PRIMARY) {\n \t\t__atomic_fetch_sub(&hw->secondary_cnt, 1, __ATOMIC_RELAXED);\n+\t\thns3_mp_uninit();\n \t\treturn 0;\n \t}\n \n@@ -1909,7 +1910,7 @@ hns3vf_dev_close(struct rte_eth_dev *eth_dev)\n \thns3vf_uninit_vf(eth_dev);\n \thns3_free_all_queues(eth_dev);\n \trte_free(hw->reset.wait_data);\n-\thns3_mp_uninit_primary();\n+\thns3_mp_uninit();\n \thns3_warn(hw, \"Close port %u finished\", hw->data->port_id);\n \n \treturn ret;\n@@ -2768,7 +2769,7 @@ hns3vf_dev_init(struct rte_eth_dev *eth_dev)\n \trte_free(hw->reset.wait_data);\n \n err_init_reset:\n-\thns3_mp_uninit_primary();\n+\thns3_mp_uninit();\n \n err_mp_init_primary:\n err_mp_init_secondary:\n@@ -2792,6 +2793,7 @@ hns3vf_dev_uninit(struct rte_eth_dev *eth_dev)\n \n \tif (rte_eal_process_type() != RTE_PROC_PRIMARY) {\n \t\t__atomic_fetch_sub(&hw->secondary_cnt, 1, __ATOMIC_RELAXED);\n+\t\thns3_mp_uninit();\n \t\treturn 0;\n \t}\n \ndiff --git a/drivers/net/hns3/hns3_mp.c b/drivers/net/hns3/hns3_mp.c\nindex 1a79d249b8..6d33bf49cd 100644\n--- a/drivers/net/hns3/hns3_mp.c\n+++ b/drivers/net/hns3/hns3_mp.c\n@@ -244,10 +244,7 @@ int hns3_mp_init_primary(void)\n \treturn 0;\n }\n \n-/*\n- * Un-initialize by primary process.\n- */\n-void hns3_mp_uninit_primary(void)\n+void hns3_mp_uninit(void)\n {\n \tprocess_data.eth_dev_cnt--;\n \ndiff --git a/drivers/net/hns3/hns3_mp.h b/drivers/net/hns3/hns3_mp.h\nindex b49532f985..5738ab74a5 100644\n--- a/drivers/net/hns3/hns3_mp.h\n+++ b/drivers/net/hns3/hns3_mp.h\n@@ -18,7 +18,7 @@ void hns3_mp_req_start_tx(struct rte_eth_dev *dev);\n void hns3_mp_req_stop_tx(struct rte_eth_dev *dev);\n \n int hns3_mp_init_primary(void);\n-void hns3_mp_uninit_primary(void);\n+void hns3_mp_uninit(void);\n int hns3_mp_init_secondary(void);\n \n #endif /* _HNS3_MP_H_ */\n", "prefixes": [ "3/4" ] }{ "id": 103378, "url": "