Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753561AbbETKWn (ORCPT ); Wed, 20 May 2015 06:22:43 -0400 Received: from mail-la0-f54.google.com ([209.85.215.54]:33619 "EHLO mail-la0-f54.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752692AbbETKWk (ORCPT ); Wed, 20 May 2015 06:22:40 -0400 MIME-Version: 1.0 In-Reply-To: <1431763110-443-4-git-send-email-yingjoe.chen@mediatek.com> References: <1431763110-443-1-git-send-email-yingjoe.chen@mediatek.com> <1431763110-443-4-git-send-email-yingjoe.chen@mediatek.com> Date: Wed, 20 May 2015 12:22:38 +0200 Message-ID: Subject: Re: [PATCH v2 3/9] clocksource: mediatek: do not enable GPT_CLK_EVT when setup From: Matthias Brugger To: Yingjoe Chen Cc: Mark Rutland , Thomas Gleixner , Russell King , Arnd Bergmann , Olof Johansson , "devicetree@vger.kernel.org" , Stephen Boyd , Pawel Moll , Catalin Marinas , Daniel Lezcano , "linux-kernel@vger.kernel.org" , Marc Carino , Rob Herring , linux-mediatek@lists.infradead.org, Sascha Hauer , srv_heupstream , "linux-arm-kernel@lists.infradead.org" Content-Type: text/plain; charset=ISO-8859-1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1498 Lines: 40 2015-05-16 9:58 GMT+02:00 Yingjoe Chen : > Spurious mtk timer interrupt is noticed at boot and cause kernel > crash. It seems if GPT is enabled, it will latch irq status even > when its IRQ is disabled. When irq is enabled afterward, we see > spurious interrupt. > Change init flow to only enable GPT_CLK_SRC at mtk_timer_init. > > Signed-off-by: Yingjoe Chen > --- > drivers/clocksource/mtk_timer.c | 15 ++++++++++----- > 1 file changed, 10 insertions(+), 5 deletions(-) > > diff --git a/drivers/clocksource/mtk_timer.c b/drivers/clocksource/mtk_timer.c > index 68ab423..91206f9 100644 > --- a/drivers/clocksource/mtk_timer.c > +++ b/drivers/clocksource/mtk_timer.c > @@ -157,8 +157,11 @@ static void mtk_timer_global_reset(struct mtk_clock_event_device *evt) > } > > static void > -mtk_timer_setup(struct mtk_clock_event_device *evt, u8 timer, u8 option) > +mtk_timer_setup(struct mtk_clock_event_device *evt, > + u8 timer, u8 option, u8 enable) Nicer would be: static void mtk_timer_setup(struct mtk_clock_event_device *evt, u8 timer, u8 option, u8 enable) Apart from that parameter enable should be of type bool. Thanks, Matthias -- motzblog.wordpress.com -- 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/