From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 1B942A046B for ; Tue, 23 Jul 2019 03:04:16 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 0E4981BEF8; Tue, 23 Jul 2019 03:04:16 +0200 (CEST) Received: from mellanox.co.il (mail-il-dmz.mellanox.com [193.47.165.129]) by dpdk.org (Postfix) with ESMTP id 2B4DD1BFDC for ; Tue, 23 Jul 2019 03:04:15 +0200 (CEST) Received: from Internal Mail-Server by MTLPINE2 (envelope-from yskoh@mellanox.com) with ESMTPS (AES256-SHA encrypted); 23 Jul 2019 04:04:12 +0300 Received: from scfae-sc-2.mti.labs.mlnx (scfae-sc-2.mti.labs.mlnx [10.101.0.96]) by labmailer.mlnx (8.13.8/8.13.8) with ESMTP id x6N11HgP026580; Tue, 23 Jul 2019 04:04:11 +0300 From: Yongseok Koh To: Ferruh Yigit Cc: dpdk stable Date: Mon, 22 Jul 2019 18:01:06 -0700 Message-Id: <20190723010115.6446-99-yskoh@mellanox.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190723010115.6446-1-yskoh@mellanox.com> References: <20190723010115.6446-1-yskoh@mellanox.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-stable] patch 'net/kni: fix return value check' has been queued to LTS release 17.11.7 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" Hi, FYI, your patch has been queued to LTS release 17.11.7 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objection by 07/27/19. So please shout if anyone has objection. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Thanks. Yongseok --- >From aae852b417fbe27abfac2eaf097d66a189f6bd16 Mon Sep 17 00:00:00 2001 From: Ferruh Yigit Date: Tue, 23 Apr 2019 16:36:21 +0100 Subject: [PATCH] net/kni: fix return value check [ backported from upstream commit 994e039b953b06a385d4362e1729a150f1a02d77 ] 'rte_kni_release()' return value is not checked, adding it. Coverity issue: 336837 Fixes: 75e2bc54c018 ("net/kni: add KNI PMD") Signed-off-by: Ferruh Yigit --- drivers/net/kni/rte_eth_kni.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/net/kni/rte_eth_kni.c b/drivers/net/kni/rte_eth_kni.c index 218d5eb583..366b2a1488 100644 --- a/drivers/net/kni/rte_eth_kni.c +++ b/drivers/net/kni/rte_eth_kni.c @@ -464,6 +464,7 @@ eth_kni_remove(struct rte_vdev_device *vdev) struct rte_eth_dev *eth_dev; struct pmd_internals *internals; const char *name; + int ret; name = rte_vdev_device_name(vdev); RTE_LOG(INFO, PMD, "Un-Initializing eth_kni for %s\n", name); @@ -476,7 +477,9 @@ eth_kni_remove(struct rte_vdev_device *vdev) eth_kni_dev_stop(eth_dev); internals = eth_dev->data->dev_private; - rte_kni_release(internals->kni); + ret = rte_kni_release(internals->kni); + if (ret) + RTE_LOG(WARNING, PMD, "Not able to release kni for %s\n", name); rte_free(internals); -- 2.21.0 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2019-07-22 17:55:11.812864888 -0700 +++ 0099-net-kni-fix-return-value-check.patch 2019-07-22 17:55:06.482475000 -0700 @@ -1,13 +1,14 @@ -From 994e039b953b06a385d4362e1729a150f1a02d77 Mon Sep 17 00:00:00 2001 +From aae852b417fbe27abfac2eaf097d66a189f6bd16 Mon Sep 17 00:00:00 2001 From: Ferruh Yigit Date: Tue, 23 Apr 2019 16:36:21 +0100 Subject: [PATCH] net/kni: fix return value check +[ backported from upstream commit 994e039b953b06a385d4362e1729a150f1a02d77 ] + 'rte_kni_release()' return value is not checked, adding it. Coverity issue: 336837 Fixes: 75e2bc54c018 ("net/kni: add KNI PMD") -Cc: stable@dpdk.org Signed-off-by: Ferruh Yigit --- @@ -15,27 +16,27 @@ 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/net/kni/rte_eth_kni.c b/drivers/net/kni/rte_eth_kni.c -index 89f44737cb..1f232e4da1 100644 +index 218d5eb583..366b2a1488 100644 --- a/drivers/net/kni/rte_eth_kni.c +++ b/drivers/net/kni/rte_eth_kni.c -@@ -459,6 +459,7 @@ eth_kni_remove(struct rte_vdev_device *vdev) +@@ -464,6 +464,7 @@ eth_kni_remove(struct rte_vdev_device *vdev) struct rte_eth_dev *eth_dev; struct pmd_internals *internals; const char *name; + int ret; name = rte_vdev_device_name(vdev); - PMD_LOG(INFO, "Un-Initializing eth_kni for %s", name); -@@ -477,7 +478,9 @@ eth_kni_remove(struct rte_vdev_device *vdev) + RTE_LOG(INFO, PMD, "Un-Initializing eth_kni for %s\n", name); +@@ -476,7 +477,9 @@ eth_kni_remove(struct rte_vdev_device *vdev) eth_kni_dev_stop(eth_dev); internals = eth_dev->data->dev_private; - rte_kni_release(internals->kni); + ret = rte_kni_release(internals->kni); + if (ret) -+ PMD_LOG(WARNING, "Not able to release kni for %s", name); ++ RTE_LOG(WARNING, PMD, "Not able to release kni for %s\n", name); - rte_eth_dev_release_port(eth_dev); + rte_free(internals); -- 2.21.0