From patchwork Sat Jan 10 00:34:21 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Stultz X-Patchwork-Id: 42930 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-la0-f70.google.com (mail-la0-f70.google.com [209.85.215.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 44F6826CF1 for ; Sat, 10 Jan 2015 00:34:45 +0000 (UTC) Received: by mail-la0-f70.google.com with SMTP id hs14sf9310200lab.1 for ; Fri, 09 Jan 2015 16:34:43 -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=Jeb5wUzo3y7Kf0bVhmyh15LLrXri+g0SZMkpyrf+5tk=; b=dvrchGW42G6WtOyJwv6L5vfa2okCb+sNSy5BKjMML8vFR49bRu5MuUXQa0WDVpZezO P6GPCUbkqYg+YX4oou5WVZj2gUVJU7c1BHb2qgibesBrlSZMvGPbzWCeyEyDGea4oVhQ wAa16JMz/2myieQd4+/VVDYQDBch+AxjDCQybFQdGRw8CWAqjqdkcAtwup4sE1ulnsB0 8paeuTBLNiMZVXI8LC39etejomcfyzMAJBxg2RGn/Uhbj6GjC/BlErW67+WFKskIHlcw 1EIy3hQmVdZ8IQ+C7bznCoRbC1KZeiVQ04WNklOvyxR2+7nL9bidXvfg77bn4EmZGRJ5 w/Bw== X-Gm-Message-State: ALoCoQl5bIqzzSPVld8tVvbYtRgtSqxmrxwv3TTZlhz49VBhx3J1iePLrXIMsgWLn5ZF5nRGO+Eb X-Received: by 10.112.9.199 with SMTP id c7mr1516351lbb.7.1420850083930; Fri, 09 Jan 2015 16:34:43 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.1.101 with SMTP id 5ls490419lal.72.gmail; Fri, 09 Jan 2015 16:34:43 -0800 (PST) X-Received: by 10.152.44.129 with SMTP id e1mr24545772lam.43.1420850083781; Fri, 09 Jan 2015 16:34:43 -0800 (PST) Received: from mail-lb0-f180.google.com (mail-lb0-f180.google.com. [209.85.217.180]) by mx.google.com with ESMTPS id w4si14627540law.77.2015.01.09.16.34.43 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 09 Jan 2015 16:34:43 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.180 as permitted sender) client-ip=209.85.217.180; Received: by mail-lb0-f180.google.com with SMTP id l4so10663987lbv.11 for ; Fri, 09 Jan 2015 16:34:43 -0800 (PST) X-Received: by 10.152.5.226 with SMTP id v2mr24574102lav.34.1420850083659; Fri, 09 Jan 2015 16:34:43 -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.9.200 with SMTP id c8csp484803lbb; Fri, 9 Jan 2015 16:34:42 -0800 (PST) X-Received: by 10.66.186.110 with SMTP id fj14mr27164152pac.98.1420850078930; Fri, 09 Jan 2015 16:34:38 -0800 (PST) Received: from mail-pa0-f43.google.com (mail-pa0-f43.google.com. [209.85.220.43]) by mx.google.com with ESMTPS id ok17si15401474pab.100.2015.01.09.16.34.38 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 09 Jan 2015 16:34:38 -0800 (PST) Received-SPF: pass (google.com: domain of john.stultz@linaro.org designates 209.85.220.43 as permitted sender) client-ip=209.85.220.43; Received: by mail-pa0-f43.google.com with SMTP id kx10so21449698pab.2 for ; Fri, 09 Jan 2015 16:34:38 -0800 (PST) X-Received: by 10.70.131.78 with SMTP id ok14mr27544199pdb.112.1420850078047; Fri, 09 Jan 2015 16:34:38 -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 hc10sm8046439pbd.78.2015.01.09.16.34.36 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 09 Jan 2015 16:34:37 -0800 (PST) From: John Stultz To: Linux Kernel Mailing List Cc: John Stultz , Dave Jones , Linus Torvalds , Thomas Gleixner , Richard Cochran , Prarit Bhargava , Stephen Boyd , Ingo Molnar , Peter Zijlstra Subject: [PATCH 03/10] clocksource: Remove clocksource_max_deferment() Date: Fri, 9 Jan 2015 16:34:21 -0800 Message-Id: <1420850068-27828-4-git-send-email-john.stultz@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1420850068-27828-1-git-send-email-john.stultz@linaro.org> References: <1420850068-27828-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.180 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 e837ffd1..0696559 100644 --- a/kernel/time/clocksource.c +++ b/kernel/time/clocksource.c @@ -575,20 +575,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) @@ -760,7 +746,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); @@ -807,7 +794,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);