[PATCH] net/ice: fix get link status timeout
Mingjin Ye
mingjinx.ye at intel.com
Mon Feb 6 07:22:39 CET 2023
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 at dpdk.org
Signed-off-by: Mingjin Ye <mingjinx.ye at 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
More information about the dev
mailing list