Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1265501 > unrolled thread

[PATCH 07/15] clocksource/drivers/h8300_timer8: Fix irq return value check

Started byDaniel Lezcano <daniel.lezcano@linaro.org>
First post2015-11-09 11:10 +0100
Last post2015-11-09 11:10 +0100
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  [PATCH 07/15] clocksource/drivers/h8300_timer8: Fix irq return value check Daniel Lezcano <daniel.lezcano@linaro.org> - 2015-11-09 11:10 +0100

#1265501 — [PATCH 07/15] clocksource/drivers/h8300_timer8: Fix irq return value check

FromDaniel Lezcano <daniel.lezcano@linaro.org>
Date2015-11-09 11:10 +0100
Subject[PATCH 07/15] clocksource/drivers/h8300_timer8: Fix irq return value check
Message-ID<qsRyF-50w-13@gated-at.bofh.it>
The value returned in case of error for the 'irq_of_parse_and_map' function is
zero in case of error. Fix the check in the init code.

Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
---
 drivers/clocksource/h8300_timer8.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/clocksource/h8300_timer8.c b/drivers/clocksource/h8300_timer8.c
index 2433325..3eedeff 100644
--- a/drivers/clocksource/h8300_timer8.c
+++ b/drivers/clocksource/h8300_timer8.c
@@ -230,7 +230,7 @@ static void __init h8300_8timer_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_reg;
 	}
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web