From: Steve Yang <stevex.yang@intel.com>
To: dev@dpdk.org
Cc: qiming.yang@intel.com, qi.z.zhang@intel.com,
Steve Yang <stevex.yang@intel.com>
Subject: [PATCH v1] net/ice/base: fix ddp pkg loaded failed
Date: Wed, 7 Sep 2022 09:10:01 +0000 [thread overview]
Message-ID: <20220907091001.68216-1-stevex.yang@intel.com> (raw)
When DDP package state is 'ICE_DDP_PKG_SAME_VERSION_ALREADY_LOADED',
it should be treated as success state, otherwise, the wrong state will
be used within 'ice_load_pkg'.
Fixes: 58e9fd55be0e ("net/ice/base: refactor DDP code")
Signed-off-by: Steve Yang <stevex.yang@intel.com>
---
drivers/net/ice/base/ice_ddp.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/net/ice/base/ice_ddp.c b/drivers/net/ice/base/ice_ddp.c
index d1cae48047..284b58a6b1 100644
--- a/drivers/net/ice/base/ice_ddp.c
+++ b/drivers/net/ice/base/ice_ddp.c
@@ -1378,8 +1378,11 @@ enum ice_ddp_state ice_init_pkg(struct ice_hw *hw, u8 *buf, u32 len)
*/
if (!state || state == ICE_DDP_PKG_ALREADY_LOADED) {
state = ice_get_pkg_info(hw);
- if (!state)
+ if (!state) {
state = ice_get_ddp_pkg_state(hw, already_loaded);
+ if (state == ICE_DDP_PKG_SAME_VERSION_ALREADY_LOADED)
+ state = ICE_SUCCESS;
+ }
}
if (ice_is_init_pkg_successful(state)) {
--
2.25.1
next reply other threads:[~2022-09-07 9:21 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-07 9:10 Steve Yang [this message]
2022-09-07 12:17 ` Zhang, Qi Z
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=20220907091001.68216-1-stevex.yang@intel.com \
--to=stevex.yang@intel.com \
--cc=dev@dpdk.org \
--cc=qi.z.zhang@intel.com \
--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).