From: Yanglong Wu <yanglong.wu@intel.com>
To: dev@dpdk.org
Cc: ryan.e.hall@intel.com, qi.z.zhang@intel.com,
Yanglong Wu <yanglong.wu@intel.com>,
stable@dpdk.org
Subject: [dpdk-dev] [PATCH v2] net/i40e: fix FPK VF overwrite PF RSS LUT
Date: Tue, 15 Jan 2019 10:23:45 +0800 [thread overview]
Message-ID: <20190115022345.108212-1-yanglong.wu@intel.com> (raw)
In-Reply-To: <20190114082405.106073-1-yanglong.wu@intel.com>
i40e_aq_set_rss_lut should set rigister according
to the vsi->type. if not, VF may overwrite the rigister
of PF
Fixes: d0a349409bd7 ("i40e: support AQ based RSS config")
Cc: stable@dpdk.org
Signed-off-by: Yanglong Wu <yanglong.wu@intel.com>
---
drivers/net/i40e/i40e_ethdev.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c
index a6b97e164..f97cd5348 100644
--- a/drivers/net/i40e/i40e_ethdev.c
+++ b/drivers/net/i40e/i40e_ethdev.c
@@ -4183,7 +4183,8 @@ i40e_get_rss_lut(struct i40e_vsi *vsi, uint8_t *lut, uint16_t lut_size)
return -EINVAL;
if (pf->flags & I40E_FLAG_RSS_AQ_CAPABLE) {
- ret = i40e_aq_get_rss_lut(hw, vsi->vsi_id, TRUE,
+ ret = i40e_aq_get_rss_lut(hw, vsi->vsi_id,
+ vsi->type != I40E_VSI_SRIOV,
lut, lut_size);
if (ret) {
PMD_DRV_LOG(ERR, "Failed to get RSS lookup table");
@@ -4222,7 +4223,8 @@ i40e_set_rss_lut(struct i40e_vsi *vsi, uint8_t *lut, uint16_t lut_size)
hw = I40E_VSI_TO_HW(vsi);
if (pf->flags & I40E_FLAG_RSS_AQ_CAPABLE) {
- ret = i40e_aq_set_rss_lut(hw, vsi->vsi_id, TRUE,
+ ret = i40e_aq_set_rss_lut(hw, vsi->vsi_id,
+ vsi->type != I40E_VSI_SRIOV,
lut, lut_size);
if (ret) {
PMD_DRV_LOG(ERR, "Failed to set RSS lookup table");
--
2.11.0
next prev parent reply other threads:[~2019-01-15 2:39 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-14 8:24 [dpdk-dev] [PATCH] " Yanglong Wu
2019-01-14 12:48 ` Zhang, Qi Z
2019-01-15 2:13 ` Wu, Yanglong
2019-01-15 2:23 ` Yanglong Wu [this message]
2019-01-15 10:51 ` [dpdk-dev] [PATCH v2] " 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=20190115022345.108212-1-yanglong.wu@intel.com \
--to=yanglong.wu@intel.com \
--cc=dev@dpdk.org \
--cc=qi.z.zhang@intel.com \
--cc=ryan.e.hall@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).