提交 dfaf820a 编写于 作者: A Axel Lin 提交者: Simon Horman

irqchip: renesas-irqc: Fix irqc_probe error handling

The code in goto err3 path is wrong because it will call fee_irq() with k == 0,
which means it does free_irq(p->irq[-1].requested_irq, &p->irq[-1]);
Signed-off-by: NAxel Lin <axel.lin@ingics.com>
Signed-off-by: NSimon Horman <horms+renesas@verge.net.au>
上级 c7788792
......@@ -248,8 +248,8 @@ static int irqc_probe(struct platform_device *pdev)
return 0;
err3:
for (; k >= 0; k--)
free_irq(p->irq[k - 1].requested_irq, &p->irq[k - 1]);
while (--k >= 0)
free_irq(p->irq[k].requested_irq, &p->irq[k]);
irq_domain_remove(p->irq_domain);
err2:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册