diff options
author | Daniel Lezcano <daniel.lezcano@linaro.org> | 2015-11-09 10:52:35 +0100 |
---|---|---|
committer | Daniel Lezcano <daniel.lezcano@linaro.org> | 2015-12-15 09:42:26 +0100 |
commit | 5019c9023251efd3bfa22b1090d8ad1901914c93 (patch) | |
tree | 39319edf81620ee7a70238aab4c4186822fb7e5f /drivers | |
parent | 903e5fd3f857c978ff8a75ae4bc5c51e6161031c (diff) | |
download | linux-5019c9023251efd3bfa22b1090d8ad1901914c93.tar.gz linux-5019c9023251efd3bfa22b1090d8ad1901914c93.tar.bz2 linux-5019c9023251efd3bfa22b1090d8ad1901914c93.zip |
clocksource/drivers/h8300_timer16: Fix irq return value check
The function irq_of_parse_and_map returns zero in case of failure.
Fix the return code test to check against zero.
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/clocksource/h8300_timer16.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/clocksource/h8300_timer16.c b/drivers/clocksource/h8300_timer16.c index 6705bf784d84..129dca02b3ee 100644 --- a/drivers/clocksource/h8300_timer16.c +++ b/drivers/clocksource/h8300_timer16.c @@ -155,7 +155,7 @@ static void __init h8300_16timer_init(struct device_node *node) } irq = irq_of_parse_and_map(node, 0); - if (irq < 0) { + if (!irq) { pr_err("failed to get irq for clockevent\n"); goto unmap_comm; } |