DPDK patches and discussions
 help / color / mirror / Atom feed
From: wangyunjian <wangyunjian@huawei.com>
To: <dev@dpdk.org>
Cc: <rmody@marvell.com>, <shshaikh@marvell.com>,
	<jerry.lilijun@huawei.com>, <xudingke@huawei.com>,
	Yunjian Wang <wangyunjian@huawei.com>, <stable@dpdk.org>
Subject: [dpdk-dev]  [PATCH] net/qede: remove dead code
Date: Fri, 17 Jul 2020 19:16:23 +0800	[thread overview]
Message-ID: <dc8bd60d5cca2b5ecf6c175745282224f3cc244f.1594984397.git.wangyunjian@huawei.com> (raw)

From: Yunjian Wang <wangyunjian@huawei.com>

This patch fixes (Logically dead code) coverity issue.

Coverity issue: 261777, 261778
Fixes: dd28bc8c6ef4 ("net/qede: fix VF port creation sequence")
Cc: stable@dpdk.org

Signed-off-by: Yunjian Wang <wangyunjian@huawei.com>
---
 drivers/net/qede/qede_rxtx.c | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/drivers/net/qede/qede_rxtx.c b/drivers/net/qede/qede_rxtx.c
index 9878ba50e..ea264f59d 100644
--- a/drivers/net/qede/qede_rxtx.c
+++ b/drivers/net/qede/qede_rxtx.c
@@ -647,8 +647,6 @@ int qede_alloc_fp_resc(struct qede_dev *qdev)
 
 	for (sb_idx = 0; sb_idx < QEDE_RXTX_MAX(qdev); sb_idx++) {
 		fp = &qdev->fp_array[sb_idx];
-		if (!fp)
-			continue;
 		fp->sb_info = rte_calloc("sb", 1, sizeof(struct ecore_sb_info),
 				RTE_CACHE_LINE_SIZE);
 		if (!fp->sb_info) {
@@ -678,8 +676,6 @@ void qede_dealloc_fp_resc(struct rte_eth_dev *eth_dev)
 
 	for (sb_idx = 0; sb_idx < QEDE_RXTX_MAX(qdev); sb_idx++) {
 		fp = &qdev->fp_array[sb_idx];
-		if (!fp)
-			continue;
 		DP_INFO(edev, "Free sb_info index 0x%x\n",
 				fp->sb_info->igu_sb_id);
 		if (fp->sb_info) {
-- 
2.23.0



             reply	other threads:[~2020-07-17 11:17 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-17 11:16 wangyunjian [this message]
2020-07-21 12:12 ` Jerin Jacob
2020-07-21 21:43 ` [dpdk-dev] [EXT] " Rasesh Mody
2020-07-22  7:45   ` Jerin Jacob
2020-07-22 12:15     ` wangyunjian
2020-07-22 12:29       ` Ferruh Yigit
2020-07-24  4:23   ` Jerin Jacob

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=dc8bd60d5cca2b5ecf6c175745282224f3cc244f.1594984397.git.wangyunjian@huawei.com \
    --to=wangyunjian@huawei.com \
    --cc=dev@dpdk.org \
    --cc=jerry.lilijun@huawei.com \
    --cc=rmody@marvell.com \
    --cc=shshaikh@marvell.com \
    --cc=stable@dpdk.org \
    --cc=xudingke@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).