DPDK patches and discussions
 help / color / mirror / Atom feed
From: Mingjin Ye <mingjinx.ye@intel.com>
To: dev@dpdk.org
Cc: stable@dpdk.org, yidingx.zhou@intel.com,
	Mingjin Ye <mingjinx.ye@intel.com>,
	Qiming Yang <qiming.yang@intel.com>,
	Qi Zhang <qi.z.zhang@intel.com>
Subject: [PATCH] net/ice: fix get link status timeout
Date: Mon,  6 Feb 2023 06:22:39 +0000	[thread overview]
Message-ID: <20230206062239.1042172-1-mingjinx.ye@intel.com> (raw)

When hw is just started, it will immediately obtain the link status, and
the longest attempt is 1 second. Some NICs are slow to initialize, which
make it fails to obtain the link status.

The patch fixes this issue by modifying the longest attempt to 5 seconds.

Fixes: cf911d90e366 ("net/ice: support link update")
Cc: stable@dpdk.org

Signed-off-by: Mingjin Ye <mingjinx.ye@intel.com>
---
 drivers/net/ice/ice_ethdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ice/ice_ethdev.c b/drivers/net/ice/ice_ethdev.c
index 0bc739daf0..eaa556f45c 100644
--- a/drivers/net/ice/ice_ethdev.c
+++ b/drivers/net/ice/ice_ethdev.c
@@ -3927,7 +3927,7 @@ static int
 ice_link_update(struct rte_eth_dev *dev, int wait_to_complete)
 {
 #define CHECK_INTERVAL 100  /* 100ms */
-#define MAX_REPEAT_TIME 10  /* 1s (10 * 100ms) in total */
+#define MAX_REPEAT_TIME 50  /* 5s (50 * 100ms) in total */
 	struct ice_hw *hw = ICE_DEV_PRIVATE_TO_HW(dev->data->dev_private);
 	struct ice_link_status link_status;
 	struct rte_eth_link link, old;
-- 
2.25.1


             reply	other threads:[~2023-02-06  6:25 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-06  6:22 Mingjin Ye [this message]
2023-02-06  7:23 ` Thomas Monjalon
2023-02-06  8:14   ` Ye, MingjinX
2023-02-06  9:15     ` Thomas Monjalon
2023-02-06 10:06       ` Ye, MingjinX
2023-02-06  7:56 韩爽
2023-02-06 10:51 ` Ye, MingjinX
2023-02-07  6:48   ` Yang, Qiming
2023-02-06  8:35 Shuang Han

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=20230206062239.1042172-1-mingjinx.ye@intel.com \
    --to=mingjinx.ye@intel.com \
    --cc=dev@dpdk.org \
    --cc=qi.z.zhang@intel.com \
    --cc=qiming.yang@intel.com \
    --cc=stable@dpdk.org \
    --cc=yidingx.zhou@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).