Skip to content

Commit 1e4d149

Browse files
joyceooi295brgl
authored andcommitted
gpio: altera: change to platform_get_irq_optional to avoid false-positive error
This patch switches to platform_get_irq_optional() from platform_get_irq() as it causes a false-positive error such as 'IRQ index 0 not found' when IRQ is not used. The IRQ usage is optional in this gpio-altera driver, so the error log is undesirable. Signed-off-by: Ooi, Joyce <[email protected]> Signed-off-by: Bartosz Golaszewski <[email protected]>
1 parent 2a2cabd commit 1e4d149

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/gpio/gpio-altera.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ static int altera_gpio_probe(struct platform_device *pdev)
266266
altera_gc->mmchip.gc.owner = THIS_MODULE;
267267
altera_gc->mmchip.gc.parent = &pdev->dev;
268268

269-
altera_gc->mapped_irq = platform_get_irq(pdev, 0);
269+
altera_gc->mapped_irq = platform_get_irq_optional(pdev, 0);
270270

271271
if (altera_gc->mapped_irq < 0)
272272
goto skip_irq;

0 commit comments

Comments
 (0)