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

net: hns3: stop mailbox handling when command queue need re-init

If the command queue needs re-initialization, the mailbox handling
task should do nothing, otherwise this task will just get some error
print.
Signed-off-by: default avatarHuazhong Tan <tanhuazhong@huawei.com>
Signed-off-by: default avatarPeng Li <lipeng321@huawei.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent cf1f2129
...@@ -2164,7 +2164,8 @@ static int hclge_mac_init(struct hclge_dev *hdev) ...@@ -2164,7 +2164,8 @@ static int hclge_mac_init(struct hclge_dev *hdev)
static void hclge_mbx_task_schedule(struct hclge_dev *hdev) static void hclge_mbx_task_schedule(struct hclge_dev *hdev)
{ {
if (!test_and_set_bit(HCLGE_STATE_MBX_SERVICE_SCHED, &hdev->state)) if (!test_bit(HCLGE_STATE_CMD_DISABLE, &hdev->state) &&
!test_and_set_bit(HCLGE_STATE_MBX_SERVICE_SCHED, &hdev->state))
schedule_work(&hdev->mbx_service_task); schedule_work(&hdev->mbx_service_task);
} }
......
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