From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754638AbcITVa7 (ORCPT ); Tue, 20 Sep 2016 17:30:59 -0400 Received: from terminus.zytor.com ([198.137.202.10]:38666 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751783AbcITVa5 (ORCPT ); Tue, 20 Sep 2016 17:30:57 -0400 Date: Tue, 20 Sep 2016 14:30:45 -0700 From: tip-bot for Paul Burton Message-ID: Cc: linux-kernel@vger.kernel.org, paul.burton@imgtec.com, hpa@zytor.com, tglx@linutronix.de, daniel.lezcano@linaro.org, mingo@kernel.org Reply-To: mingo@kernel.org, daniel.lezcano@linaro.org, tglx@linutronix.de, paul.burton@imgtec.com, hpa@zytor.com, linux-kernel@vger.kernel.org In-Reply-To: <20160913165644.627-1-paul.burton@imgtec.com> References: <20160913165644.627-1-paul.burton@imgtec.com> To: linux-tip-commits@vger.kernel.org Subject: [tip:timers/core] clocksource/mips-gic-timer: Print an error if IRQ setup fails Git-Commit-ID: 2fd0c93cd219779eef4b1301f9613e43adc86e39 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: 2fd0c93cd219779eef4b1301f9613e43adc86e39 Gitweb: http://git.kernel.org/tip/2fd0c93cd219779eef4b1301f9613e43adc86e39 Author: Paul Burton AuthorDate: Tue, 13 Sep 2016 17:56:43 +0100 Committer: Thomas Gleixner 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 Cc: linux-mips@linux-mips.org Cc: Daniel Lezcano Link: http://lkml.kernel.org/r/20160913165644.627-1-paul.burton@imgtec.com Signed-off-by: Thomas Gleixner --- 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,