summaryrefslogtreecommitdiff
path: root/drivers/gpio/gpio-dwapb.c
diff options
context:
space:
mode:
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>2020-05-19 16:12:31 +0300
committerLinus Walleij <linus.walleij@linaro.org>2020-05-25 11:05:09 +0200
commitd7cc23604f367c0d0f272f0af55e2032de50a053 (patch)
tree428892b10f029ca27dbd50ef65e324f5b0bf9aff /drivers/gpio/gpio-dwapb.c
parent494a94e38dcf62543a32a4424d646ff80b4b28bd (diff)
gpio: dwapb: avoid error message for optional IRQ
platform_get_irq() will generate an error message if the requested IRQ is not present. Use platform_get_irq_optional() to avoid the error message being generated. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Tested-by: Serge Semin <fancer.lancer@gmail.com> Reviewed-by: Serge Semin <fancer.lancer@gmail.com> Acked-by: Serge Semin <fancer.lancer@gmail.com> Link: https://lore.kernel.org/r/20200519131233.59032-2-andriy.shevchenko@linux.intel.com Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/gpio/gpio-dwapb.c')
-rw-r--r--drivers/gpio/gpio-dwapb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpio/gpio-dwapb.c b/drivers/gpio/gpio-dwapb.c
index e5d844304f8d..944dae80d687 100644
--- a/drivers/gpio/gpio-dwapb.c
+++ b/drivers/gpio/gpio-dwapb.c
@@ -549,7 +549,7 @@ static void dwapb_get_irq(struct device *dev, struct fwnode_handle *fwnode,
if (np)
pp->irq[j] = of_irq_get(np, j);
else if (has_acpi_companion(dev))
- pp->irq[j] = platform_get_irq(to_platform_device(dev), j);
+ pp->irq[j] = platform_get_irq_optional(to_platform_device(dev), j);
if (pp->irq[j] >= 0)
pp->has_irq = true;