From patchwork Sat Mar 7 02:49:54 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Stultz X-Patchwork-Id: 45504 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wi0-f198.google.com (mail-wi0-f198.google.com [209.85.212.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id ACE56214A0 for ; Sat, 7 Mar 2015 02:50:23 +0000 (UTC) Received: by widex7 with SMTP id ex7sf1778240wid.2 for ; Fri, 06 Mar 2015 18:50:23 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=h9DMYZ8jAjvooy6OUROXJMv5VC0xK1h1pjJZy7OLnBE=; b=VZdMc3vTfPA5EJdjZo8gAb4PWZIDoiBX7FHh3LSNIILMZT0NRtVHRAdAEnq+NuABX5 BabeT0+ob0p/SFEymtiG/wP9vssUiJyRklCa3MSyMy1O55k67jmmQJscA6c5/1u0uUoF PBmXldtiuhV+uEvhdkjAL9xfZuM1ICiwSD2GQ7QzNz+daCfYpcPOr29Hi3p9wVNg5p0Z 0beOMz484maorLUfu9WTFuTrJMUIcQyCD1OMvL0+Xp2etq6XP2Qsm5ZZh4OqPqPYMvwy fsNX+yvTjZXAdcziFMlrtTp+af/jf62BTb0vSen/KRXwdlfC6boD63rOQKVdnobAk5bv tezw== X-Gm-Message-State: ALoCoQn26/ehEHTH74mVi9cOmrq26i1w3WFwa3WYdW+KhREuySJV1ipHr1y4WeaeDzHPJYqEvJG+ X-Received: by 10.152.4.229 with SMTP id n5mr2728407lan.1.1425696622760; Fri, 06 Mar 2015 18:50:22 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.197.97 with SMTP id it1ls139840lac.1.gmail; Fri, 06 Mar 2015 18:50:22 -0800 (PST) X-Received: by 10.152.43.51 with SMTP id t19mr15319406lal.73.1425696622404; Fri, 06 Mar 2015 18:50:22 -0800 (PST) Received: from mail-lb0-f179.google.com (mail-lb0-f179.google.com. [209.85.217.179]) by mx.google.com with ESMTPS id mp6si8591271lbb.4.2015.03.06.18.50.22 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 06 Mar 2015 18:50:22 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.179 as permitted sender) client-ip=209.85.217.179; Received: by lbjb6 with SMTP id b6so26040422lbj.9 for ; Fri, 06 Mar 2015 18:50:22 -0800 (PST) X-Received: by 10.112.147.104 with SMTP id tj8mr15742772lbb.106.1425696621946; Fri, 06 Mar 2015 18:50:21 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.112.35.133 with SMTP id h5csp256396lbj; Fri, 6 Mar 2015 18:50:21 -0800 (PST) X-Received: by 10.66.224.164 with SMTP id rd4mr30652090pac.12.1425696620242; Fri, 06 Mar 2015 18:50:20 -0800 (PST) Received: from mail-pd0-f173.google.com (mail-pd0-f173.google.com. [209.85.192.173]) by mx.google.com with ESMTPS id xp7si17565008pab.119.2015.03.06.18.50.19 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 06 Mar 2015 18:50:20 -0800 (PST) Received-SPF: pass (google.com: domain of john.stultz@linaro.org designates 209.85.192.173 as permitted sender) client-ip=209.85.192.173; Received: by pdbfp1 with SMTP id fp1so42464463pdb.7 for ; Fri, 06 Mar 2015 18:50:19 -0800 (PST) X-Received: by 10.66.159.138 with SMTP id xc10mr30747513pab.141.1425696619363; Fri, 06 Mar 2015 18:50:19 -0800 (PST) Received: from localhost.localdomain (c-67-170-153-23.hsd1.or.comcast.net. [67.170.153.23]) by mx.google.com with ESMTPSA id a2sm8381456pbu.27.2015.03.06.18.50.17 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 06 Mar 2015 18:50:17 -0800 (PST) From: John Stultz To: lkml Cc: John Stultz , Dave Jones , Linus Torvalds , Thomas Gleixner , Richard Cochran , Prarit Bhargava , Stephen Boyd , Ingo Molnar , Peter Zijlstra Subject: [PATCH 03/12] clocksource: Remove clocksource_max_deferment() Date: Fri, 6 Mar 2015 18:49:54 -0800 Message-Id: <1425696603-16878-4-git-send-email-john.stultz@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1425696603-16878-1-git-send-email-john.stultz@linaro.org> References: <1425696603-16878-1-git-send-email-john.stultz@linaro.org> X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: john.stultz@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.179 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , clocksource_max_deferment() doesn't do anything useful anymore, so zap it. Cc: Dave Jones Cc: Linus Torvalds Cc: Thomas Gleixner Cc: Richard Cochran Cc: Prarit Bhargava Cc: Stephen Boyd Cc: Ingo Molnar Cc: Peter Zijlstra Signed-off-by: John Stultz --- kernel/time/clocksource.c | 20 ++++---------------- 1 file changed, 4 insertions(+), 16 deletions(-) diff --git a/kernel/time/clocksource.c b/kernel/time/clocksource.c index e5d00e6..4988411 100644 --- a/kernel/time/clocksource.c +++ b/kernel/time/clocksource.c @@ -499,20 +499,6 @@ u64 clocks_calc_max_nsecs(u32 mult, u32 shift, u32 maxadj, u64 mask) return max_nsecs; } -/** - * clocksource_max_deferment - Returns max time the clocksource should be deferred - * @cs: Pointer to clocksource - * - */ -static u64 clocksource_max_deferment(struct clocksource *cs) -{ - u64 max_nsecs; - - max_nsecs = clocks_calc_max_nsecs(cs->mult, cs->shift, cs->maxadj, - cs->mask); - return max_nsecs; -} - #ifndef CONFIG_ARCH_USES_GETTIMEOFFSET static struct clocksource *clocksource_find_best(bool oneshot, bool skipcur) @@ -684,7 +670,8 @@ void __clocksource_updatefreq_scale(struct clocksource *cs, u32 scale, u32 freq) cs->maxadj = clocksource_max_adjustment(cs); } - cs->max_idle_ns = clocksource_max_deferment(cs); + cs->max_idle_ns = clocks_calc_max_nsecs(cs->mult, cs->shift, + cs->maxadj, cs->mask); } EXPORT_SYMBOL_GPL(__clocksource_updatefreq_scale); @@ -731,7 +718,8 @@ int clocksource_register(struct clocksource *cs) cs->name); /* calculate max idle time permitted for this clocksource */ - cs->max_idle_ns = clocksource_max_deferment(cs); + cs->max_idle_ns = clocks_calc_max_nsecs(cs->mult, cs->shift, + cs->maxadj, cs->mask); mutex_lock(&clocksource_mutex); clocksource_enqueue(cs);