projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1b2eb89
)
irqchip/aspeed-i2c-ic: Fix irq_of_parse_and_map() return value
author
Krzysztof Kozlowski
<krzysztof.kozlowski@linaro.org>
Sat, 23 Apr 2022 09:42:26 +0000
(11:42 +0200)
committer
Marc Zyngier
<maz@kernel.org>
Wed, 4 May 2022 15:37:48 +0000
(16:37 +0100)
The irq_of_parse_and_map() returns 0 on failure, not a negative ERRNO.
Fixes: f48e699ddf70 ("irqchip/aspeed-i2c-ic: Add I2C IRQ controller for Aspeed")
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link:
https://lore.kernel.org/r/20220423094227.33148-1-krzysztof.kozlowski@linaro.org
drivers/irqchip/irq-aspeed-i2c-ic.c
patch
|
blob
|
history
diff --git
a/drivers/irqchip/irq-aspeed-i2c-ic.c
b/drivers/irqchip/irq-aspeed-i2c-ic.c
index a47db16ff9603e1ab18575521d768c0d64198447..9c9fc3e2967ede2e3be21895af3d20229ee4ab8e 100644
(file)
--- a/
drivers/irqchip/irq-aspeed-i2c-ic.c
+++ b/
drivers/irqchip/irq-aspeed-i2c-ic.c
@@
-77,8
+77,8
@@
static int __init aspeed_i2c_ic_of_init(struct device_node *node,
}
i2c_ic->parent_irq = irq_of_parse_and_map(node, 0);
- if (
i2c_ic->parent_irq < 0
) {
- ret =
i2c_ic->parent_irq
;
+ if (
!i2c_ic->parent_irq
) {
+ ret =
-EINVAL
;
goto err_iounmap;
}