From: Hongbo Zheng Date: Sun, 13 Jun 2021 02:31:51 +0000 (+0800) Subject: net/hns3: increase VF reset retry maximum X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=b25987fa7e25b3ba852f9433d22761c006884205;p=dpdk.git net/hns3: increase VF reset retry maximum When the device is very busy, VF reset may have to be retried many times to succeed, leading to the current max reset fail retry count not enough. Modify max reset fail retry count to 30 to enhance the reliability of reset function. Fixes: 2790c6464725 ("net/hns3: support device reset") Cc: stable@dpdk.org Signed-off-by: Hongbo Zheng Signed-off-by: Min Hu (Connor) --- diff --git a/drivers/net/hns3/hns3_intr.c b/drivers/net/hns3/hns3_intr.c index 6bdb17f622..0b307fdd1d 100644 --- a/drivers/net/hns3/hns3_intr.c +++ b/drivers/net/hns3/hns3_intr.c @@ -2582,7 +2582,7 @@ hns3_clear_reset_level(struct hns3_hw *hw, uint64_t *levels) static bool hns3_reset_err_handle(struct hns3_adapter *hns) { -#define MAX_RESET_FAIL_CNT 5 +#define MAX_RESET_FAIL_CNT 30 struct hns3_hw *hw = &hns->hw; @@ -2676,7 +2676,7 @@ hns3_reset_pre(struct hns3_adapter *hns) static int hns3_reset_post(struct hns3_adapter *hns) { -#define TIMEOUT_RETRIES_CNT 5 +#define TIMEOUT_RETRIES_CNT 30 struct hns3_hw *hw = &hns->hw; struct timeval tv_delta; struct timeval tv;