提交 c609c05d 编写于 作者: D David Jander 提交者: Grant Likely

gpio/pca953x: Fix IRQ support.

It seems that in the normal case, IRQ_NOREQUEST needs to be explicitly
cleared, otherwise claiming the interrupt fails.
In the case of sparse interrupts, the descriptor needs to be allocated
first.
Signed-off-by: NDavid Jander <david@protonic.nl>
Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
上级 8e46ea3e
......@@ -517,8 +517,10 @@ static int pca953x_irq_setup(struct pca953x_chip *chip,
static void pca953x_irq_teardown(struct pca953x_chip *chip)
{
if (chip->irq_base != -1)
if (chip->irq_base != -1) {
irq_free_descs(chip->irq_base, chip->gpio_chip.ngpio);
free_irq(chip->client->irq, chip);
}
}
#else /* CONFIG_GPIO_PCA953X_IRQ */
static int pca953x_irq_setup(struct pca953x_chip *chip,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册