Received: by 2002:ac0:8c9a:0:0:0:0:0 with SMTP id r26csp4504365ima; Mon, 4 Feb 2019 18:29:24 -0800 (PST) X-Google-Smtp-Source: AHgI3IaAaz7SmMJHXtPimo1Lqoi9ZgfdTaQIEHd0+wLv6qtRpQ2/Y3xAalhoiB63Kj48qm3vrkms X-Received: by 2002:a63:2784:: with SMTP id n126mr2417835pgn.48.1549333764118; Mon, 04 Feb 2019 18:29:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1549333764; cv=none; d=google.com; s=arc-20160816; b=DQs/cQquUtd6A2raVyFj4M9MB3FTT5mayvjQ/FSMniSIJcM+2lg92uUlOx/lUamkrX HcrVDK1pypQOq0U0KzFwqNt2dg0RC6p/GlA3NVPVzdzXf472ruhStIR0HAuvyqdgQOCl Ot4OdDXLp5DJXdpELRUqILSu45LgNeVbbkKsAUziZLmy23qxRr4ZfRtV01o4444RLhS9 UmblvNVKpbyA276jmar6Y20ysfS2y03g0birk1k8N0Ch+44Ma9wlWbPUjvita4gQLfxA FZzKbaosFlwcgONGyc5+eoSCV9uJdhxZMxfOi2q2o1/YJizXIWnpYzMwFfHwO+6L4zpT mPpw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=8yKYhikQZxCUa/cCc0k1fLcffd+7gOuz7prbBCzKXrw=; b=FPrshAR/+ww9H9IZ/cxEb5NnIv7yjeoCpqEWomH6vg72UJ0FOCWERffK4EeeF4F4Hk krSsrtIi4hCzO2JdehCld3PglhtYjKsm1kOLZLhRaKp6dxWs0dxw8GeEWoyQy5j+fFwJ Ebc3uVJAfBJR/hs6Xel28hHLZiGqPhfaLx6Hy6XCJGMAgXSeh4w69u4w93lBAe4Z/wma aBYgWmOH8NiTrLc6AQu+utbqfh7Lbkq9VjCxM3ZavAFsPSh4yDLwaJ/EbEGCsPmkVi69 55n9xIYmDoMVPBaMO4uVJzIEkcxxdvoN9HXgRiDHjmo2TiNpCoQ6EIZb1QMUAJI6C0Rd fyew== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@lechnology.com header.s=default header.b=baffNN5q; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r2si1633076pgo.483.2019.02.04.18.29.08; Mon, 04 Feb 2019 18:29:24 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@lechnology.com header.s=default header.b=baffNN5q; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727361AbfBECSn (ORCPT + 99 others); Mon, 4 Feb 2019 21:18:43 -0500 Received: from vern.gendns.com ([98.142.107.122]:51146 "EHLO vern.gendns.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726727AbfBECSn (ORCPT ); Mon, 4 Feb 2019 21:18:43 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lechnology.com; s=default; h=Content-Transfer-Encoding:Content-Type: In-Reply-To:MIME-Version:Date:Message-ID:From:References:Cc:To:Subject:Sender :Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help: List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=8yKYhikQZxCUa/cCc0k1fLcffd+7gOuz7prbBCzKXrw=; b=baffNN5q3Q/aiNryDJRQaOooJP OJKUJUiGzX2IZm0+MlVdeh21v43M7OI8ApJOmjOdwWEeZ5cSWR9c5I2j4r10oH84lTtfpdH8vFCI8 EXmZgqVW38jiW06rDLzm1gvXBUokTRxl5yN0/AmRSFTfIHmOza4PyiDo9QeKJ3G7UQ71rt+aZ1xPu Z2p6k4372eh8tjDouLYFXTC6tVQ+e9Gpr1OqnpSxqyczuPOUicDOL67gJRPg4EbaVTvSYvN4Zwc4t +Pe1fKXM8bfKHGUM1p0I8MLy735I5sfIdH8XkQUOUuJMUI9+a6BLgFHjEiZMmmjpfpNYfaFGF8o6E FrDEEx+Q==; Received: from 108-198-5-147.lightspeed.okcbok.sbcglobal.net ([108.198.5.147]:34230 helo=[192.168.0.134]) by vern.gendns.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES128-GCM-SHA256:128) (Exim 4.91) (envelope-from ) id 1gqqGO-0004Oe-Mm; Mon, 04 Feb 2019 21:15:04 -0500 Subject: Re: [PATCH v2 04/12] ARM: davinci: WARN_ON() if clk_get() fails To: Bartosz Golaszewski , Sekhar Nori , Kevin Hilman , Daniel Lezcano , Rob Herring , Mark Rutland , Thomas Gleixner Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Bartosz Golaszewski References: <20190204171757.32073-1-brgl@bgdev.pl> <20190204171757.32073-5-brgl@bgdev.pl> From: David Lechner Message-ID: <0750392d-e298-b467-24c0-3c2779ead3f7@lechnology.com> Date: Mon, 4 Feb 2019 20:18:38 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.4.0 MIME-Version: 1.0 In-Reply-To: <20190204171757.32073-5-brgl@bgdev.pl> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - vern.gendns.com X-AntiAbuse: Original Domain - vger.kernel.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - lechnology.com X-Get-Message-Sender-Via: vern.gendns.com: authenticated_id: davidmain+lechnology.com/only user confirmed/virtual account not confirmed X-Authenticated-Sender: vern.gendns.com: davidmain@lechnology.com X-Source: X-Source-Args: X-Source-Dir: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2/4/19 11:17 AM, Bartosz Golaszewski wrote: > From: Bartosz Golaszewski > > Currently the timer code checks if the clock pointer passed to it is > good (!IS_ERR(clk)). The new clocksource driver expects the clock to > be functional and doesn't perform any checks so emit a warning if > clk_get() fails. Apply this to all davinci platforms. > > Signed-off-by: Bartosz Golaszewski > --- > arch/arm/mach-davinci/da830.c | 4 ++++ > arch/arm/mach-davinci/da850.c | 4 ++++ > arch/arm/mach-davinci/dm355.c | 4 ++++ > arch/arm/mach-davinci/dm365.c | 4 ++++ > arch/arm/mach-davinci/dm644x.c | 4 ++++ > arch/arm/mach-davinci/dm646x.c | 4 ++++ > 6 files changed, 24 insertions(+) > > diff --git a/arch/arm/mach-davinci/da830.c b/arch/arm/mach-davinci/da830.c > index 2cc9fe4c3a91..9a4b749cbb6b 100644 > --- a/arch/arm/mach-davinci/da830.c > +++ b/arch/arm/mach-davinci/da830.c > @@ -834,6 +834,10 @@ void __init da830_init_time(void) > da830_pll_init(NULL, pll, NULL); > > clk = clk_get(NULL, "timer0"); > + if (WARN_ON(IS_ERR(clk))) { > + pr_err("Unable to get the timer clock\n"); Do we really need a warning _and_ an error? > + return; > + } > > davinci_timer_init(clk); > }