DPDK patches and discussions
 help / color / mirror / Atom feed
From: taox.zhu@intel.com
To: beilei.xing@intel.com, qi.z.zhang@intel.com
Cc: dev@dpdk.org, Zhu Tao <taox.zhu@intel.com>, stable@dpdk.org
Subject: [dpdk-dev] [PATCH v2] net/i40e: fix request queue fail in VF
Date: Fri, 19 Jul 2019 11:18:04 +0800	[thread overview]
Message-ID: <20190719031804.7392-1-taox.zhu@intel.com> (raw)
In-Reply-To: <20190718145351.13987-1-taox.zhu@intel.com>

From: Zhu Tao <taox.zhu@intel.com>

When the VF configuration is larger than the number of queues reserved
by PF, VF sends the request queue command through admin queue. When PF
received this command, it may reset the VF and send a notification
before resetting. If this notification is read by the timed task alarm,
Task request queue will lost notification. This patch Mark vf_reset,
pend_msg flag just as task request queue has received notification in
task alarm.

Fixes: 864a800d70 ("net/i40e: remove VF interrupt handler")
Fixes: ee653bd800 ("net/i40e: determine number of queues per VF at run time")
Cc: stable@dpdk.org

Signed-off-by: Zhu Tao <taox.zhu@intel.com>
---
 drivers/net/i40e/i40e_ethdev_vf.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/net/i40e/i40e_ethdev_vf.c b/drivers/net/i40e/i40e_ethdev_vf.c
index 5be32b069..3b9740c08 100644
--- a/drivers/net/i40e/i40e_ethdev_vf.c
+++ b/drivers/net/i40e/i40e_ethdev_vf.c
@@ -1332,6 +1332,10 @@ i40evf_handle_pf_event(struct rte_eth_dev *dev, uint8_t *msg,
 		PMD_DRV_LOG(DEBUG, "VIRTCHNL_EVENT_RESET_IMPENDING event");
 		_rte_eth_dev_callback_process(dev, RTE_ETH_EVENT_INTR_RESET,
 					      NULL);
+		if (!vf->vf_reset) {
+			vf->vf_reset = true;
+			vf->pend_msg |= PFMSG_RESET_IMPENDING;
+		}
 		break;
 	case VIRTCHNL_EVENT_LINK_CHANGE:
 		PMD_DRV_LOG(DEBUG, "VIRTCHNL_EVENT_LINK_CHANGE event");
-- 
2.17.1


  parent reply	other threads:[~2019-07-19  3:20 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-18 14:53 [dpdk-dev] [PATCH] " taox.zhu
2019-07-18 13:09 ` Ye Xiaolong
2019-07-18  7:05   ` Zhu, TaoX
2019-07-18 14:05     ` Ye Xiaolong
2019-07-19  3:18 ` taox.zhu [this message]
2019-07-23  6:52   ` [dpdk-dev] [PATCH v2] " Zhang, Qi Z
2019-07-24  8:32   ` [dpdk-dev] [PATCH v3] " taox.zhu
2019-07-24 12:54     ` 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=20190719031804.7392-1-taox.zhu@intel.com \
    --to=taox.zhu@intel.com \
    --cc=beilei.xing@intel.com \
    --cc=dev@dpdk.org \
    --cc=qi.z.zhang@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).