From: "Zhang, Qi Z" <qi.z.zhang@intel.com>
To: "Zhu, TaoX" <taox.zhu@intel.com>, "Xing, Beilei" <beilei.xing@intel.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>, "stable@dpdk.org" <stable@dpdk.org>
Subject: Re: [dpdk-dev] [PATCH v2] net/i40e: fix request queue fail in VF
Date: Tue, 23 Jul 2019 06:52:20 +0000 [thread overview]
Message-ID: <039ED4275CED7440929022BC67E7061153D6B677@SHSMSX105.ccr.corp.intel.com> (raw)
In-Reply-To: <20190719031804.7392-1-taox.zhu@intel.com>
> -----Original Message-----
> From: Zhu, TaoX
> Sent: Friday, July 19, 2019 11:18 AM
> To: Xing, Beilei <beilei.xing@intel.com>; Zhang, Qi Z <qi.z.zhang@intel.com>
> Cc: dev@dpdk.org; Zhu, TaoX <taox.zhu@intel.com>; stable@dpdk.org
> Subject: [PATCH v2] net/i40e: fix request queue fail in VF
>
> 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;
You current solution rely on we can always can get a dummy event after the VIRTCHNL_EVENT_RESET_IMPENDING event we needed, but I'm not sure if it is guaranteed
If the issue is due to the race condition between i40evf_execute_vf_cmd and i40evf_dev_alarm_handler
Why not just disable the adminq interrupt before i40evf_request_queues and enable it back after it?
> + }
> break;
> case VIRTCHNL_EVENT_LINK_CHANGE:
> PMD_DRV_LOG(DEBUG, "VIRTCHNL_EVENT_LINK_CHANGE event");
> --
> 2.17.1
next prev parent reply other threads:[~2019-07-23 6:56 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 ` [dpdk-dev] [PATCH v2] " taox.zhu
2019-07-23 6:52 ` Zhang, Qi Z [this message]
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=039ED4275CED7440929022BC67E7061153D6B677@SHSMSX105.ccr.corp.intel.com \
--to=qi.z.zhang@intel.com \
--cc=beilei.xing@intel.com \
--cc=dev@dpdk.org \
--cc=stable@dpdk.org \
--cc=taox.zhu@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).