diff options
author | Huazhong Tan <tanhuazhong@huawei.com> | 2018-11-07 12:06:08 +0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-11-07 11:42:17 -0800 |
commit | 720bd5837e3721f553a896a00da4a99ea12f0551 (patch) | |
tree | e629e38583d9bc7f8e1aee49dea8f347953efb68 /drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_main.h | |
parent | net: hns3: use HNS3_NIC_STATE_INITED to indicate the initialization state of enet (diff) | |
download | linux-dev-720bd5837e3721f553a896a00da4a99ea12f0551.tar.xz linux-dev-720bd5837e3721f553a896a00da4a99ea12f0551.zip |
net: hns3: add set_default_reset_request in the hnae3_ae_ops
Currently, when reset_event is called because of tx timeout, it will
upgrade the reset level (For PF, HNAE3_FUNC_RESET -> HNAE3_CORE_RESET
-> HNAE3_GLOBAL_RESET) if the time between the new reset and last reset
is within 20 secs, or restore the reset level to HNAE3_FUNC_RESET if
the time between the new reset and last reset is over 20 secs.
There is requirement that the caller needs to decide the reset level
when triggering a reset, for example, RAS recovery. So this patch
adds the set_default_reset_request to meet this requirement.
Signed-off-by: Huazhong Tan <tanhuazhong@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to '')
-rw-r--r-- | drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_main.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_main.h b/drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_main.h index aed241e8ffab..6b2fd5a0326f 100644 --- a/drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_main.h +++ b/drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_main.h @@ -145,6 +145,7 @@ struct hclgevf_dev { struct hclgevf_misc_vector misc_vector; struct hclgevf_rss_cfg rss_cfg; unsigned long state; + unsigned long default_reset_request; #define HCLGEVF_RESET_REQUESTED 0 #define HCLGEVF_RESET_PENDING 1 |