提交 ae064e61 编写于 作者: Q qumingguang 提交者: David S. Miller

net: hns3: Fix a misuse to devm_free_irq

we should use free_irq to free the nic irq during the unloading time.
because we use request_irq to apply it when nic up. It will crash if
up net device after reset the port. This patch fixes the issue.
Signed-off-by: Nqumingguang <qumingguang@huawei.com>
Signed-off-by: NLipeng <lipeng321@huawei.com>
Signed-off-by: NYunsheng Lin <linyunsheng@huawei.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 bb6b94a8
......@@ -2558,9 +2558,8 @@ static int hns3_nic_uninit_vector_data(struct hns3_nic_priv *priv)
(void)irq_set_affinity_hint(
priv->tqp_vector[i].vector_irq,
NULL);
devm_free_irq(&pdev->dev,
priv->tqp_vector[i].vector_irq,
&priv->tqp_vector[i]);
free_irq(priv->tqp_vector[i].vector_irq,
&priv->tqp_vector[i]);
}
priv->ring_data[i].ring->irq_init_flag = HNS3_VECTOR_NOT_INITED;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册