Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752007AbcDRJIZ (ORCPT ); Mon, 18 Apr 2016 05:08:25 -0400 Received: from mail-wm0-f46.google.com ([74.125.82.46]:36398 "EHLO mail-wm0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751719AbcDRJIX (ORCPT ); Mon, 18 Apr 2016 05:08:23 -0400 Date: Mon, 18 Apr 2016 11:08:18 +0200 From: Daniel Lezcano To: Vineet Gupta Cc: linux-snps-arc@lists.infradead.org, linux-kernel@vger.kernel.org, Jason Cooper , Marc Zyngier , Noam Camus Subject: Re: [PATCH v5] ARC: clockevent: DT based probe Message-ID: <20160418090818.GA14358@linaro.org> References: <20160414100518.GB15250@linaro.org> <1460961970-20696-1-git-send-email-vgupta@synopsys.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1460961970-20696-1-git-send-email-vgupta@synopsys.com> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1466 Lines: 47 On Mon, Apr 18, 2016 at 12:16:10PM +0530, Vineet Gupta wrote: > - timer frequency is derived from DT (no longer rely on top level > DT "clock-frequency" probed early and exported by asm/clk.h) > > - TIMER0_IRQ need not be exported across arch code, confined to intc as > it is property of same > > - Any failures in clockevent setup are considered pedantic and system > panic()'s as there is no generic fallback (unlike clocksource where > a jiffies based soft clocksource always exists) > > Cc: Daniel Lezcano > Signed-off-by: Vineet Gupta > --- > Changes since v4 [*] > - clockevent setup failure panic()s bubbled up to top level function [Daniel] > - arc_get_timer_clk() returns error status vs. void [Daniel] > - For consistency, straggler pr_err() in setup function also converted to panic > > [*] http://lists.infradead.org/pipermail/linux-snps-arc/2016-April/000903.html [ ... ] > +static int noinline arc_get_timer_clk(struct device_node *node) > +{ > + struct clk *clk; > + int ret = -1; > + > + clk = of_clk_get(node, 0); > + if (IS_ERR(clk)) { > + pr_err("timer missing clk"); > + return ret; > + } return PTR_ERR(clk); > + ret = clk_prepare_enable(clk); > + if (ret) { > + pr_err("Couldn't enable parent clk\n"); > + return ret; > + } > + > + arc_timer_freq = clk_get_rate(clk); > + return ret; > +} With the change above: Acked-by: Daniel Lezcano