提交 c21f7a52 编写于 作者: M Milton Miller 提交者: Benjamin Herrenschmidt

hvc_console: Call free_irq() only if request_irq() was successful

Only call free_irq if we marked the request_irq has having succeeded
instead of whenever the the sub-driver identified the interrupt to use.
Signed-off-by: NMilton Miller <miltonm@bga.com>
Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
上级 9fef3d2d
...@@ -37,7 +37,7 @@ int notifier_add_irq(struct hvc_struct *hp, int irq) ...@@ -37,7 +37,7 @@ int notifier_add_irq(struct hvc_struct *hp, int irq)
void notifier_del_irq(struct hvc_struct *hp, int irq) void notifier_del_irq(struct hvc_struct *hp, int irq)
{ {
if (!irq) if (!hp->irq_requested)
return; return;
free_irq(irq, hp); free_irq(irq, hp);
hp->irq_requested = 0; hp->irq_requested = 0;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册