From: Slawomir Mrozowicz <slawomirx.mrozowicz@intel.com>
To: helin.zhang@intel.com, jingjing.wu@intel.com
Cc: dev@dpdk.org, Slawomir Mrozowicz <slawomirx.mrozowicz@intel.com>
Subject: [dpdk-dev] [PATCH] i40e: Unchecked return value
Date: Mon, 23 May 2016 14:25:15 +0200 [thread overview]
Message-ID: <1464006315-9537-1-git-send-email-slawomirx.mrozowicz@intel.com> (raw)
Calling i40e_switch_tx_queue without checking return value.
Fixed by add warning log information if return failed.
Fixes: 71d35259ff67 ("i40e: tear down flow director")
Coverity ID 13208
Signed-off-by: Slawomir Mrozowicz <slawomirx.mrozowicz@intel.com>
---
drivers/net/i40e/i40e_fdir.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/net/i40e/i40e_fdir.c b/drivers/net/i40e/i40e_fdir.c
index 8aa41e5..d0bdf2c 100644
--- a/drivers/net/i40e/i40e_fdir.c
+++ b/drivers/net/i40e/i40e_fdir.c
@@ -288,11 +288,14 @@ i40e_fdir_teardown(struct i40e_pf *pf)
{
struct i40e_hw *hw = I40E_PF_TO_HW(pf);
struct i40e_vsi *vsi;
+ int err = I40E_SUCCESS;
vsi = pf->fdir.fdir_vsi;
if (!vsi)
return;
- i40e_switch_tx_queue(hw, vsi->base_queue, FALSE);
+ err = i40e_switch_tx_queue(hw, vsi->base_queue, FALSE);
+ if (err)
+ PMD_DRV_LOG(WARNING, "Failed to do FDIR TX switch off.");
i40e_switch_rx_queue(hw, vsi->base_queue, FALSE);
i40e_dev_rx_queue_release(pf->fdir.rxq);
pf->fdir.rxq = NULL;
--
1.9.1
next reply other threads:[~2016-05-23 12:19 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-05-23 12:25 Slawomir Mrozowicz [this message]
2016-05-24 0:34 ` Zhang, Helin
2016-06-13 10:04 ` Bruce Richardson
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=1464006315-9537-1-git-send-email-slawomirx.mrozowicz@intel.com \
--to=slawomirx.mrozowicz@intel.com \
--cc=dev@dpdk.org \
--cc=helin.zhang@intel.com \
--cc=jingjing.wu@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).