Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1482641 > unrolled thread
| Started by | Paul Burton <paul.burton@imgtec.com> |
|---|---|
| First post | 2016-09-13 19:00 +0200 |
| Last post | 2016-09-20 23:40 +0200 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
[PATCH 1/2] clocksource: mips-gic-timer: Print an error if IRQ setup fails Paul Burton <paul.burton@imgtec.com> - 2016-09-13 19:00 +0200
[tip:timers/core] clocksource/mips-gic-timer: Print an error if IRQ setup fails tip-bot for Paul Burton <tipbot@zytor.com> - 2016-09-20 23:40 +0200
| From | Paul Burton <paul.burton@imgtec.com> |
|---|---|
| Date | 2016-09-13 19:00 +0200 |
| Subject | [PATCH 1/2] clocksource: mips-gic-timer: Print an error if IRQ setup fails |
| Message-ID | <sgZdT-4vC-9@gated-at.bofh.it> |
We've checked for errors from setup_irq_percpu since commit f95ac8558b88
("CLOCKSOURCE: mips-gic: Add missing error returns checks") but didn't
print an error message in the failure case. This makes it very easy to
overlook the GIC timer clock event driver not being registered, since
we'll generally just use a different clock event driver if that happens.
Print an error if IRQ setup fails in order to make such problems harder
to miss (ie. not completely silent).
Signed-off-by: Paul Burton <paul.burton@imgtec.com>
Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: linux-kernel@vger.kernel.org
Cc: linux-mips@linux-mips.org
---
drivers/clocksource/mips-gic-timer.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/clocksource/mips-gic-timer.c b/drivers/clocksource/mips-gic-timer.c
index b4b3ab5..802055b 100644
--- a/drivers/clocksource/mips-gic-timer.c
+++ b/drivers/clocksource/mips-gic-timer.c
@@ -113,8 +113,11 @@ static int gic_clockevent_init(void)
return -ENXIO;
ret = setup_percpu_irq(gic_timer_irq, &gic_compare_irqaction);
- if (ret < 0)
+ if (ret < 0) {
+ pr_err("GIC timer IRQ %d setup failed: %d\n",
+ gic_timer_irq, ret);
return ret;
+ }
cpuhp_setup_state(CPUHP_AP_MIPS_GIC_TIMER_STARTING,
"AP_MIPS_GIC_TIMER_STARTING", gic_starting_cpu,
--
2.9.3
[toc] | [next] | [standalone]
| From | tip-bot for Paul Burton <tipbot@zytor.com> |
|---|---|
| Date | 2016-09-20 23:40 +0200 |
| Subject | [tip:timers/core] clocksource/mips-gic-timer: Print an error if IRQ setup fails |
| Message-ID | <sjAVI-8wm-19@gated-at.bofh.it> |
| In reply to | #1482641 |
Commit-ID: 2fd0c93cd219779eef4b1301f9613e43adc86e39
Gitweb: http://git.kernel.org/tip/2fd0c93cd219779eef4b1301f9613e43adc86e39
Author: Paul Burton <paul.burton@imgtec.com>
AuthorDate: Tue, 13 Sep 2016 17:56:43 +0100
Committer: Thomas Gleixner <tglx@linutronix.de>
CommitDate: Tue, 20 Sep 2016 23:24:33 +0200
clocksource/mips-gic-timer: Print an error if IRQ setup fails
We've checked for errors from setup_irq_percpu since commit f95ac8558b88
("CLOCKSOURCE: mips-gic: Add missing error returns checks") but didn't
print an error message in the failure case. This makes it very easy to
overlook the GIC timer clock event driver not being registered, since
we'll generally just use a different clock event driver if that happens.
Print an error if IRQ setup fails in order to make such problems harder
to miss (ie. not completely silent).
Signed-off-by: Paul Burton <paul.burton@imgtec.com>
Cc: linux-mips@linux-mips.org
Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
Link: http://lkml.kernel.org/r/20160913165644.627-1-paul.burton@imgtec.com
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
---
drivers/clocksource/mips-gic-timer.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/clocksource/mips-gic-timer.c b/drivers/clocksource/mips-gic-timer.c
index b4b3ab5..802055b 100644
--- a/drivers/clocksource/mips-gic-timer.c
+++ b/drivers/clocksource/mips-gic-timer.c
@@ -113,8 +113,11 @@ static int gic_clockevent_init(void)
return -ENXIO;
ret = setup_percpu_irq(gic_timer_irq, &gic_compare_irqaction);
- if (ret < 0)
+ if (ret < 0) {
+ pr_err("GIC timer IRQ %d setup failed: %d\n",
+ gic_timer_irq, ret);
return ret;
+ }
cpuhp_setup_state(CPUHP_AP_MIPS_GIC_TIMER_STARTING,
"AP_MIPS_GIC_TIMER_STARTING", gic_starting_cpu,
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web