aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpio/gpio-xilinx.c
diff options
context:
space:
mode:
authorSrinivas Neeli <[email protected]>2021-06-03 16:49:00 +0000
committerBartosz Golaszewski <[email protected]>2021-06-14 20:13:23 +0000
commitbe4dc321a55cfee3099a1bd9399d0cd4ac080c23 (patch)
tree095e412916ba0957531d543e60fb8f4af6c17d54 /drivers/gpio/gpio-xilinx.c
parentgpio: zynq: Check return value of irq_get_irq_data (diff)
downloadkernel-be4dc321a55cfee3099a1bd9399d0cd4ac080c23.tar.gz
kernel-be4dc321a55cfee3099a1bd9399d0cd4ac080c23.zip
gpio: gpio-xilinx: update on suspend and resume calls
Current AXI GPIO driver checking for interrupt data in suspend and resume path and reporting as error in case of no interrupt connection. As per AXI GPIO IP specification interrupt connection is optional, driver logic is updated in suspend and resume calls by reporting debug message and enable/disable clock in case of no connection. Signed-off-by: Srinivas Neeli <[email protected]> Signed-off-by: Bartosz Golaszewski <[email protected]>
Diffstat (limited to 'drivers/gpio/gpio-xilinx.c')
-rw-r--r--drivers/gpio/gpio-xilinx.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/gpio/gpio-xilinx.c b/drivers/gpio/gpio-xilinx.c
index 0c43baa54b5b..e10e7752460a 100644
--- a/drivers/gpio/gpio-xilinx.c
+++ b/drivers/gpio/gpio-xilinx.c
@@ -313,8 +313,8 @@ static int __maybe_unused xgpio_suspend(struct device *dev)
struct irq_data *data = irq_get_irq_data(gpio->irq);
if (!data) {
- dev_err(dev, "irq_get_irq_data() failed\n");
- return -EINVAL;
+ dev_dbg(dev, "IRQ not connected\n");
+ return pm_runtime_force_suspend(dev);
}
if (!irqd_is_wakeup_set(data))
@@ -359,8 +359,8 @@ static int __maybe_unused xgpio_resume(struct device *dev)
struct irq_data *data = irq_get_irq_data(gpio->irq);
if (!data) {
- dev_err(dev, "irq_get_irq_data() failed\n");
- return -EINVAL;
+ dev_dbg(dev, "IRQ not connected\n");
+ return pm_runtime_force_resume(dev);
}
if (!irqd_is_wakeup_set(data))