From patchwork Mon Apr 21 09:55:07 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 28684 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-yh0-f70.google.com (mail-yh0-f70.google.com [209.85.213.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 1CFF42032B for ; Mon, 21 Apr 2014 09:59:41 +0000 (UTC) Received: by mail-yh0-f70.google.com with SMTP id 29sf12196499yhl.1 for ; Mon, 21 Apr 2014 02:59:40 -0700 (PDT) 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:in-reply-to:references :sender:precedence:list-id:x-original-sender :x-original-authentication-results:mailing-list:list-post:list-help :list-archive:list-unsubscribe; bh=PHi3z7Z60/lTVj0vmF7fIKu/7e2zsPQkxlXcz9Ramco=; b=WWXm39fKVGxxLIF9vVTvJdNmHaNjeHwLhhe0iMzJBxK4PlbKzHXHpiwIkbmImJuZl/ KwgEhucdzprkFMd4MuZM0/rxL6Qdtnk6EEk9uVGspAcgGyLxYXDXzX8SocX/CCar/ZZI kS/NT+JNvgGVGirszE2j/dkjgbV9IEsXIjWH6UFYleeyQnh4d6kQFVRMM9Jod+4wUFv+ s986GCdBDNJxIzLI65MLaAa03ayywUUJdJ0TkHyVXUazyaQnNaBRdeDa/VWvbyy5/Yrf b3BoxaTDTzHOdR49PL0kM1NE3f7YVr56Lwtd+bKDeNwWEYcVpIAfEpqZ6ALxfDPefFb3 536A== X-Gm-Message-State: ALoCoQlLjh1WqneSXykb6rGthU5UF5goX3kWToW6tu0XNp2HBbjIwcfAsccrEP6CV5O7vqdSlBpT X-Received: by 10.236.126.72 with SMTP id a48mr16154939yhi.49.1398074380866; Mon, 21 Apr 2014 02:59:40 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.101.213 with SMTP id u79ls600260qge.79.gmail; Mon, 21 Apr 2014 02:59:40 -0700 (PDT) X-Received: by 10.52.108.164 with SMTP id hl4mr2110620vdb.25.1398074380753; Mon, 21 Apr 2014 02:59:40 -0700 (PDT) Received: from mail-ve0-f182.google.com (mail-ve0-f182.google.com [209.85.128.182]) by mx.google.com with ESMTPS id cq3si6183552vcb.162.2014.04.21.02.59.40 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 21 Apr 2014 02:59:40 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.128.182 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.128.182; Received: by mail-ve0-f182.google.com with SMTP id jw12so7801273veb.27 for ; Mon, 21 Apr 2014 02:59:40 -0700 (PDT) X-Received: by 10.58.202.133 with SMTP id ki5mr28651169vec.19.1398074380680; Mon, 21 Apr 2014 02:59:40 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.220.221.72 with SMTP id ib8csp280387vcb; Mon, 21 Apr 2014 02:59:40 -0700 (PDT) X-Received: by 10.68.136.2 with SMTP id pw2mr904260pbb.167.1398074379919; Mon, 21 Apr 2014 02:59:39 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id yb4si16330919pab.144.2014.04.21.02.59.39; Mon, 21 Apr 2014 02:59:39 -0700 (PDT) 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; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752459AbaDUJ7Z (ORCPT + 26 others); Mon, 21 Apr 2014 05:59:25 -0400 Received: from mail-we0-f181.google.com ([74.125.82.181]:41279 "EHLO mail-we0-f181.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751897AbaDUJ42 (ORCPT ); Mon, 21 Apr 2014 05:56:28 -0400 Received: by mail-we0-f181.google.com with SMTP id q58so3488548wes.40 for ; Mon, 21 Apr 2014 02:56:27 -0700 (PDT) X-Received: by 10.180.83.196 with SMTP id s4mr13489116wiy.24.1398074187816; Mon, 21 Apr 2014 02:56:27 -0700 (PDT) Received: from localhost ([213.122.173.131]) by mx.google.com with ESMTPSA id gz1sm15231114wib.14.2014.04.21.02.56.24 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Mon, 21 Apr 2014 02:56:27 -0700 (PDT) From: Viresh Kumar To: tglx@linutronix.de Cc: linaro-kernel@lists.linaro.org, linaro-networking@linaro.org, linux-kernel@vger.kernel.org, fweisbec@gmail.com, Viresh Kumar Subject: [PATCH V2 11/19] tick-common: remove tick_check_replacement() Date: Mon, 21 Apr 2014 15:25:07 +0530 Message-Id: <03a6046b4db8c6587f75775b274e2fd3655a550c.1398072824.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 1.7.12.rc2.18.g61b472e In-Reply-To: References: In-Reply-To: References: Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: viresh.kumar@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.128.182 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , tick_check_replacement() is now nothing more than a dummy wrapper over tick_check_preferred() and can be removed. Signed-off-by: Viresh Kumar --- kernel/time/clockevents.c | 2 +- kernel/time/tick-common.c | 16 +++++----------- kernel/time/tick-internal.h | 2 +- 3 files changed, 7 insertions(+), 13 deletions(-) diff --git a/kernel/time/clockevents.c b/kernel/time/clockevents.c index a3e9333..15ff71d 100644 --- a/kernel/time/clockevents.c +++ b/kernel/time/clockevents.c @@ -298,7 +298,7 @@ static int clockevents_replace(struct clock_event_device *ced) if (dev == ced || dev->mode != CLOCK_EVT_MODE_UNUSED) continue; - if (!tick_check_replacement(newdev, dev)) + if (!tick_check_preferred(newdev, dev)) continue; if (!try_module_get(dev->owner)) diff --git a/kernel/time/tick-common.c b/kernel/time/tick-common.c index 9d3106b..896c992 100644 --- a/kernel/time/tick-common.c +++ b/kernel/time/tick-common.c @@ -230,7 +230,11 @@ static bool tick_check_percpu(struct clock_event_device *curdev, return true; } -static bool tick_check_preferred(struct clock_event_device *curdev, +/* + * Check whether the new device is a better fit than curdev. curdev + * can be NULL ! + */ +bool tick_check_preferred(struct clock_event_device *curdev, struct clock_event_device *newdev) { if (!tick_check_percpu(curdev, newdev, smp_processor_id())) @@ -254,16 +258,6 @@ static bool tick_check_preferred(struct clock_event_device *curdev, } /* - * Check whether the new device is a better fit than curdev. curdev - * can be NULL ! - */ -bool tick_check_replacement(struct clock_event_device *curdev, - struct clock_event_device *newdev) -{ - return tick_check_preferred(curdev, newdev); -} - -/* * Check, if the new registered device should be used. Called with * clockevents_lock held and interrupts disabled. */ diff --git a/kernel/time/tick-internal.h b/kernel/time/tick-internal.h index 65f080a..8c6e85d 100644 --- a/kernel/time/tick-internal.h +++ b/kernel/time/tick-internal.h @@ -24,7 +24,7 @@ extern void tick_handover_do_timer(int *cpup); extern void tick_shutdown(unsigned int *cpup); extern void tick_suspend(void); extern void tick_resume(void); -extern bool tick_check_replacement(struct clock_event_device *curdev, +extern bool tick_check_preferred(struct clock_event_device *curdev, struct clock_event_device *newdev); extern void tick_install_replacement(struct clock_event_device *dev);