Skip to content

Commit 814d0c7

Browse files
Jie Wangdavem330
authored andcommitted
net: hns3: fix reset delay time to avoid configuration timeout
Currently the hns3 vf function reset delays 5000ms before vf rebuild process. In product applications, this delay is too long for application configurations and causes configuration timeout. According to the tests, 500ms delay is enough for reset process except PF FLR. So this patch modifies delay to 500ms in these scenarios. Fixes: 6988eb2 ("net: hns3: Add support to reset the enet/ring mgmt layer") Signed-off-by: Jie Wang <[email protected]> Signed-off-by: Hao Lan <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent f14db07 commit 814d0c7

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_main.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1436,7 +1436,10 @@ static int hclgevf_reset_wait(struct hclgevf_dev *hdev)
14361436
* might happen in case reset assertion was made by PF. Yes, this also
14371437
* means we might end up waiting bit more even for VF reset.
14381438
*/
1439-
msleep(5000);
1439+
if (hdev->reset_type == HNAE3_VF_FULL_RESET)
1440+
msleep(5000);
1441+
else
1442+
msleep(500);
14401443

14411444
return 0;
14421445
}

0 commit comments

Comments
 (0)