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>,
stable@dpdk.org
Subject: [PATCH v1] net/ice/base: fix switch rules not cleared on warm reset
Date: Fri, 12 Aug 2022 02:52:54 +0000 [thread overview]
Message-ID: <20220812025254.145132-1-stevex.yang@intel.com> (raw)
When users killed app forcely (e.g.: kill -9 pid), the driver reset
couldn't make all registers of NIC recovery to initial status.
For example, the switch filter rules, which involved the vlan tag,
couldn't be added.
Tell the Firmware to shut down the AdminQ to avoid possible error
when process was killed abnormally.
Fixes: 453d087ccaff ("net/ice/base: add common functions")
Cc: stable@dpdk.org
Signed-off-by: Steve Yang <stevex.yang@intel.com>
---
drivers/net/ice/base/ice_common.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/drivers/net/ice/base/ice_common.c b/drivers/net/ice/base/ice_common.c
index db87bacd97..66b51be29d 100644
--- a/drivers/net/ice/base/ice_common.c
+++ b/drivers/net/ice/base/ice_common.c
@@ -926,6 +926,11 @@ enum ice_status ice_init_hw(struct ice_hw *hw)
if (status)
goto err_unroll_cqinit;
+ /* Tell the Firmware to shut down the AdminQ to avoid possible error
+ * when process was killed abnormally.
+ */
+ ice_aq_q_shutdown(hw, true);
+
status = ice_init_nvm(hw);
if (status)
goto err_unroll_cqinit;
--
2.25.1
reply other threads:[~2022-08-12 3:03 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20220812025254.145132-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 \
--cc=stable@dpdk.org \
/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).