diff options
author | Lubomir Rintel <lkundrak@v3.sk> | 2020-01-28 22:08:45 +0100 |
---|---|---|
committer | Bartosz Golaszewski <bgolaszewski@baylibre.com> | 2020-02-10 10:50:58 +0100 |
commit | a630fe34ddc09ec9b82df4867a8680d0929fe926 (patch) | |
tree | 0c7fc55e3220f7e07488d6a0611be869f384e47e /drivers/gpio/gpio-pxa.c | |
parent | bb6d3fb354c5ee8d6bde2d576eb7220ea09862b9 (diff) | |
download | linux-a630fe34ddc09ec9b82df4867a8680d0929fe926.tar.bz2 |
gpio: pxa: Avoid a warning when gpio0 and gpio1 IRQS are not there
Not all platforms use those. Let's use
platform_get_irq_byname_optional() instead platform_get_irq_byname() so
that we avoid a useless warning:
[ 1.359455] pxa-gpio d4019000.gpio: IRQ gpio0 not found
[ 1.359583] pxa-gpio d4019000.gpio: IRQ gpio1 not found
Signed-off-by: Lubomir Rintel <lkundrak@v3.sk>
Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
Diffstat (limited to 'drivers/gpio/gpio-pxa.c')
-rw-r--r-- | drivers/gpio/gpio-pxa.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpio/gpio-pxa.c b/drivers/gpio/gpio-pxa.c index 9888b62f37af..567742d962ae 100644 --- a/drivers/gpio/gpio-pxa.c +++ b/drivers/gpio/gpio-pxa.c @@ -652,8 +652,8 @@ static int pxa_gpio_probe(struct platform_device *pdev) if (!pchip->irqdomain) return -ENOMEM; - irq0 = platform_get_irq_byname(pdev, "gpio0"); - irq1 = platform_get_irq_byname(pdev, "gpio1"); + irq0 = platform_get_irq_byname_optional(pdev, "gpio0"); + irq1 = platform_get_irq_byname_optional(pdev, "gpio1"); irq_mux = platform_get_irq_byname(pdev, "gpio_mux"); if ((irq0 > 0 && irq1 <= 0) || (irq0 <= 0 && irq1 > 0) || (irq_mux <= 0)) |