DPDK patches and discussions
 help / color / mirror / Atom feed
From: Qi Zhang <qi.z.zhang@intel.com>
To: qiming.yang@intel.com
Cc: dev@dpdk.org, Qi Zhang <qi.z.zhang@intel.com>
Subject: [dpdk-dev] [PATCH] net/ice/base: remove unnecessary code
Date: Mon, 10 May 2021 11:23:26 +0800	[thread overview]
Message-ID: <20210510032326.3163171-1-qi.z.zhang@intel.com> (raw)

Coverty issue: 370613
Execution cannot reach this statement: "break;".
Remove the unnecessary if branch.

Fixes: 2913bc4155d2 ("net/ice/base: sign external device package programming")

Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
---
 drivers/net/ice/base/ice_common.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/drivers/net/ice/base/ice_common.c b/drivers/net/ice/base/ice_common.c
index ac412a1aa7..cf0a7d4e7f 100644
--- a/drivers/net/ice/base/ice_common.c
+++ b/drivers/net/ice/base/ice_common.c
@@ -2009,9 +2009,6 @@ ice_parse_common_caps(struct ice_hw *hw, struct ice_hw_common_caps *caps,
 	{
 		u8 index = cap - ICE_AQC_CAPS_EXT_TOPO_DEV_IMG0;
 
-		if (index >= ICE_EXT_TOPO_DEV_IMG_COUNT)
-			break;
-
 		caps->ext_topo_dev_img_ver_high[index] = number;
 		caps->ext_topo_dev_img_ver_low[index] = logical_id;
 		caps->ext_topo_dev_img_part_num[index] =
-- 
2.26.2


             reply	other threads:[~2021-05-10  3:19 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-10  3:23 Qi Zhang [this message]
2021-05-10  5:02 ` Yang, Qiming
2021-05-10  5:44   ` Zhang, Qi Z
  -- strict thread matches above, loose matches on Subject: below --
2021-05-10  3:21 Qi Zhang
2020-04-07  0:25 Qi Zhang
2020-04-08  7:02 ` Ye Xiaolong

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=20210510032326.3163171-1-qi.z.zhang@intel.com \
    --to=qi.z.zhang@intel.com \
    --cc=dev@dpdk.org \
    --cc=qiming.yang@intel.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).