summaryrefslogtreecommitdiff
path: root/drivers/soc/xilinx/zynqmp_power.c
diff options
context:
space:
mode:
authorRuan Jinjie <ruanjinjie@huawei.com>2023-08-03 13:48:07 +0300
committerMichal Simek <michal.simek@amd.com>2023-08-04 09:53:21 +0300
commit746db5d0b6d2a4bce0bc972bffd8428c606106cd (patch)
tree09ac52f3ca6d8e90987be73058b951e9c4160a73 /drivers/soc/xilinx/zynqmp_power.c
parentc6cb31b9f61c5261f9a0d7dc38b8f84a850bfcee (diff)
downloadlinux-746db5d0b6d2a4bce0bc972bffd8428c606106cd.tar.xz
soc: xilinx: Do not check for 0 return after calling platform_get_irq()
There is no possible for platform_get_irq() to return 0. Use the return value from platform_get_irq(). Signed-off-by: Ruan Jinjie <ruanjinjie@huawei.com> Link: https://lore.kernel.org/r/20230803104807.814005-3-ruanjinjie@huawei.com Signed-off-by: Michal Simek <michal.simek@amd.com>
Diffstat (limited to 'drivers/soc/xilinx/zynqmp_power.c')
-rw-r--r--drivers/soc/xilinx/zynqmp_power.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/soc/xilinx/zynqmp_power.c b/drivers/soc/xilinx/zynqmp_power.c
index 913417506468..c2c819701eec 100644
--- a/drivers/soc/xilinx/zynqmp_power.c
+++ b/drivers/soc/xilinx/zynqmp_power.c
@@ -243,8 +243,8 @@ static int zynqmp_pm_probe(struct platform_device *pdev)
}
} else if (of_property_present(pdev->dev.of_node, "interrupts")) {
irq = platform_get_irq(pdev, 0);
- if (irq <= 0)
- return -ENXIO;
+ if (irq < 0)
+ return irq;
ret = devm_request_threaded_irq(&pdev->dev, irq, NULL,
zynqmp_pm_isr,