提交 fb50cdfe 编写于 作者: W William Breathitt Gray 提交者: Linus Walleij

gpio: 104-idio-16: Disable IRQ on device probe

IRQ should be disabled on device probe so that the device IRQ is in a
known starting state. If IRQ is not disabled, interrupts may be reported
as handled by the IRQ handler, despite no irq_unmask calls made by the
user.
Signed-off-by: NWilliam Breathitt Gray <vilhelm.gray@gmail.com>
Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
上级 d9110e9c
...@@ -242,6 +242,9 @@ static int __init idio_16_probe(struct platform_device *pdev) ...@@ -242,6 +242,9 @@ static int __init idio_16_probe(struct platform_device *pdev)
goto err_gpio_register; goto err_gpio_register;
} }
/* Disable IRQ by default */
outb(0, base + 2);
err = gpiochip_irqchip_add(&idio16gpio->chip, &idio_16_irqchip, 0, err = gpiochip_irqchip_add(&idio16gpio->chip, &idio_16_irqchip, 0,
handle_edge_irq, IRQ_TYPE_NONE); handle_edge_irq, IRQ_TYPE_NONE);
if (err) { if (err) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册