Commit 5a4b584
net: hns3: fixed reset failure issues caused by the incorrect reset type
When a reset type that is not supported by the driver is input, a reset
pending flag bit of the HNAE3_NONE_RESET type is generated in
reset_pending. The driver does not have a mechanism to clear this type
of error. As a result, the driver considers that the reset is not
complete. This patch provides a mechanism to clear the
HNAE3_NONE_RESET flag and the parameter of
hnae3_ae_ops.set_default_reset_request is verified.
The error message:
hns3 0000:39:01.0: cmd failed -16
hns3 0000:39:01.0: hclge device re-init failed, VF is disabled!
hns3 0000:39:01.0: failed to reset VF stack
hns3 0000:39:01.0: failed to reset VF(4)
hns3 0000:39:01.0: prepare reset(2) wait done
hns3 0000:39:01.0 eth4: already uninitialized
Use the crash tool to view struct hclgevf_dev:
struct hclgevf_dev {
...
default_reset_request = 0x20,
reset_level = HNAE3_NONE_RESET,
reset_pending = 0x100,
reset_type = HNAE3_NONE_RESET,
...
};
Fixes: 720bd58 ("net: hns3: add set_default_reset_request in the hnae3_ae_ops")
Signed-off-by: Hao Lan <[email protected]>
Signed-off-by: Jijie Shao <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Jakub Kicinski <[email protected]>1 parent 80fb40b commit 5a4b584
File tree
2 files changed
+61
-10
lines changed- drivers/net/ethernet/hisilicon/hns3
- hns3pf
- hns3vf
2 files changed
+61
-10
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3574 | 3574 | | |
3575 | 3575 | | |
3576 | 3576 | | |
| 3577 | + | |
| 3578 | + | |
| 3579 | + | |
| 3580 | + | |
| 3581 | + | |
| 3582 | + | |
| 3583 | + | |
| 3584 | + | |
| 3585 | + | |
| 3586 | + | |
| 3587 | + | |
3577 | 3588 | | |
3578 | 3589 | | |
3579 | 3590 | | |
| |||
3594 | 3605 | | |
3595 | 3606 | | |
3596 | 3607 | | |
3597 | | - | |
| 3608 | + | |
3598 | 3609 | | |
3599 | 3610 | | |
3600 | 3611 | | |
| |||
3604 | 3615 | | |
3605 | 3616 | | |
3606 | 3617 | | |
3607 | | - | |
| 3618 | + | |
3608 | 3619 | | |
3609 | 3620 | | |
3610 | 3621 | | |
| |||
4052 | 4063 | | |
4053 | 4064 | | |
4054 | 4065 | | |
4055 | | - | |
| 4066 | + | |
4056 | 4067 | | |
4057 | 4068 | | |
4058 | 4069 | | |
| |||
4086 | 4097 | | |
4087 | 4098 | | |
4088 | 4099 | | |
| 4100 | + | |
| 4101 | + | |
4089 | 4102 | | |
4090 | 4103 | | |
4091 | 4104 | | |
| |||
4227 | 4240 | | |
4228 | 4241 | | |
4229 | 4242 | | |
4230 | | - | |
| 4243 | + | |
4231 | 4244 | | |
4232 | 4245 | | |
4233 | 4246 | | |
| |||
4470 | 4483 | | |
4471 | 4484 | | |
4472 | 4485 | | |
| 4486 | + | |
| 4487 | + | |
| 4488 | + | |
| 4489 | + | |
4473 | 4490 | | |
4474 | 4491 | | |
| 4492 | + | |
| 4493 | + | |
| 4494 | + | |
| 4495 | + | |
| 4496 | + | |
| 4497 | + | |
| 4498 | + | |
| 4499 | + | |
4475 | 4500 | | |
4476 | 4501 | | |
4477 | 4502 | | |
| |||
Lines changed: 32 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1393 | 1393 | | |
1394 | 1394 | | |
1395 | 1395 | | |
| 1396 | + | |
| 1397 | + | |
| 1398 | + | |
| 1399 | + | |
| 1400 | + | |
| 1401 | + | |
| 1402 | + | |
| 1403 | + | |
| 1404 | + | |
| 1405 | + | |
| 1406 | + | |
1396 | 1407 | | |
1397 | 1408 | | |
1398 | 1409 | | |
| |||
1542 | 1553 | | |
1543 | 1554 | | |
1544 | 1555 | | |
1545 | | - | |
| 1556 | + | |
1546 | 1557 | | |
1547 | 1558 | | |
1548 | 1559 | | |
| |||
1662 | 1673 | | |
1663 | 1674 | | |
1664 | 1675 | | |
| 1676 | + | |
| 1677 | + | |
1665 | 1678 | | |
1666 | 1679 | | |
1667 | 1680 | | |
| |||
1671 | 1684 | | |
1672 | 1685 | | |
1673 | 1686 | | |
1674 | | - | |
1675 | | - | |
1676 | 1687 | | |
1677 | 1688 | | |
1678 | 1689 | | |
1679 | 1690 | | |
1680 | 1691 | | |
1681 | 1692 | | |
| 1693 | + | |
| 1694 | + | |
| 1695 | + | |
1682 | 1696 | | |
1683 | 1697 | | |
1684 | 1698 | | |
| |||
1689 | 1703 | | |
1690 | 1704 | | |
1691 | 1705 | | |
| 1706 | + | |
| 1707 | + | |
| 1708 | + | |
| 1709 | + | |
| 1710 | + | |
1692 | 1711 | | |
1693 | 1712 | | |
| 1713 | + | |
| 1714 | + | |
| 1715 | + | |
| 1716 | + | |
| 1717 | + | |
| 1718 | + | |
| 1719 | + | |
1694 | 1720 | | |
1695 | 1721 | | |
1696 | 1722 | | |
| |||
1847 | 1873 | | |
1848 | 1874 | | |
1849 | 1875 | | |
1850 | | - | |
| 1876 | + | |
1851 | 1877 | | |
1852 | 1878 | | |
1853 | 1879 | | |
1854 | 1880 | | |
1855 | 1881 | | |
1856 | 1882 | | |
1857 | | - | |
| 1883 | + | |
1858 | 1884 | | |
1859 | 1885 | | |
1860 | 1886 | | |
| |||
1977 | 2003 | | |
1978 | 2004 | | |
1979 | 2005 | | |
1980 | | - | |
| 2006 | + | |
1981 | 2007 | | |
1982 | 2008 | | |
1983 | 2009 | | |
| |||
0 commit comments