From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754284AbcFAOn5 (ORCPT ); Wed, 1 Jun 2016 10:43:57 -0400 Received: from mail-wm0-f50.google.com ([74.125.82.50]:35309 "EHLO mail-wm0-f50.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751624AbcFAOn4 (ORCPT ); Wed, 1 Jun 2016 10:43:56 -0400 Subject: Re: [PATCH 7/9] clocksource/drivers/cadence_ttc: Convert init function to return error To: =?UTF-8?Q?S=c3=b6ren_Brinkmann?= References: <1464770093-12667-1-git-send-email-daniel.lezcano@linaro.org> <1464770093-12667-8-git-send-email-daniel.lezcano@linaro.org> <20160601143622.GA3766@xsjsorenbubuntu> Cc: tglx@linutronix.de, linux-kernel@vger.kernel.org, Michal Simek , "moderated list:ARM/ZYNQ ARCHITEC..." From: Daniel Lezcano Message-ID: <574EF4A9.7010405@linaro.org> Date: Wed, 1 Jun 2016 16:43:53 +0200 User-Agent: Mozilla/5.0 (X11; Linux i686; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 MIME-Version: 1.0 In-Reply-To: <20160601143622.GA3766@xsjsorenbubuntu> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 06/01/2016 04:36 PM, Sören Brinkmann wrote: > Hi Daniel, Hi Soren, [ ... ] >> + err = clk_notifier_register(ttcce->ttc.clk, >> + &ttcce->ttc.clk_rate_change_nb); >> + if (err) { >> pr_warn("Unable to register clock notifier.\n"); >> + return err; > > So far we handle this as warning only and move on, as the notifier is > only needed when frequency scaling is enabled. And even then, the effect > is usually just that timing is off. Ok, I will fix it. [ ... ] >> - static int initialized; >> - int clksel; >> + int clksel, ret; >> u32 timer_width = 16; >> >> - if (initialized) >> - return; >> - >> - initialized = 1; >> - > > This also changes behavior. We have multiple of these timer modules in > our HW and we don't want them all to be used for time keeping. This > construct made sure that we only use the first timer for which init is > called leaving the others for non-OS purposes. Ha, yes. My bad, this change was not supposed to be here. Thanks for spotting this. -- Daniel -- Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog