Commit afb6afdb authored by Huazhong Tan's avatar Huazhong Tan Committed by David S. Miller

net: hns3: set VF's default reset_type to HNAE3_NONE_RESET

reset_type means what kind of reset the driver is handling now,
so after initializing or reset, the reset_type of VF should be
set to HNAE3_NONE_RESET, otherwise, this unknown default value
may be a little misleading when the device is running.
Signed-off-by: default avatarHuazhong Tan <tanhuazhong@huawei.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 08bb3857
...@@ -1862,6 +1862,7 @@ static void hclgevf_reset_service_task(struct hclgevf_dev *hdev) ...@@ -1862,6 +1862,7 @@ static void hclgevf_reset_service_task(struct hclgevf_dev *hdev)
hclgevf_reset_task_schedule(hdev); hclgevf_reset_task_schedule(hdev);
} }
hdev->reset_type = HNAE3_NONE_RESET;
clear_bit(HCLGEVF_STATE_RST_HANDLING, &hdev->state); clear_bit(HCLGEVF_STATE_RST_HANDLING, &hdev->state);
up(&hdev->reset_sem); up(&hdev->reset_sem);
} }
...@@ -2742,6 +2743,7 @@ static int hclgevf_init_hdev(struct hclgevf_dev *hdev) ...@@ -2742,6 +2743,7 @@ static int hclgevf_init_hdev(struct hclgevf_dev *hdev)
hclgevf_state_init(hdev); hclgevf_state_init(hdev);
hdev->reset_level = HNAE3_VF_FUNC_RESET; hdev->reset_level = HNAE3_VF_FUNC_RESET;
hdev->reset_type = HNAE3_NONE_RESET;
ret = hclgevf_misc_irq_init(hdev); ret = hclgevf_misc_irq_init(hdev);
if (ret) { if (ret) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment