From patchwork Fri Mar 28 11:41:35 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 27273 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ie0-f197.google.com (mail-ie0-f197.google.com [209.85.223.197]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 7A3A620062 for ; Fri, 28 Mar 2014 11:44:07 +0000 (UTC) Received: by mail-ie0-f197.google.com with SMTP id rd18sf17281120iec.0 for ; Fri, 28 Mar 2014 04:44:06 -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=iOVN1om/Ehxjb6jf7eTmd30jdbPg8SveV6H71bm+/VI=; b=AMr3ZbY7qC7HOPMTz8DXMq1UO5qJO2zYFAxluihtdprgoIvxyrnEC85llniwRpNJP7 3WtK+BOphwDCdTGKAM4igz3z3iS3L4IJ1EkD4h0xtTGTc2GAdeJ0cS8yehI0ATBO/rn1 pdMDBeTebYF5tuID2e59/1aaG+xkfjkvrhkat/G3bQ1t+X2RbIvZpESKjUZlSHmfiwus iM81h52k+hmmelKZqRBjoHLOAZ0fYiQIFtvmGOMmk3NRRKdKswJOv51R7tL9PoQzSzYV FVj3UsXFLsx1kIAWOlQmq87AQ/jcBVv0zy37Y1n4VhLJk9yFIa+PU7reeBzBhizjFwe5 wn5Q== X-Gm-Message-State: ALoCoQnv0ZOXTsQaXmoW6IbUulvJPDr0Y6hS3bgXkGrCiXL1Ad7YCFKxYYRq4CSvjx6vRDsFat1Y X-Received: by 10.43.78.135 with SMTP id zm7mr2764092icb.27.1396007046926; Fri, 28 Mar 2014 04:44:06 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.84.103 with SMTP id k94ls855407qgd.93.gmail; Fri, 28 Mar 2014 04:44:06 -0700 (PDT) X-Received: by 10.58.229.4 with SMTP id sm4mr6993861vec.10.1396007046721; Fri, 28 Mar 2014 04:44:06 -0700 (PDT) Received: from mail-ve0-f180.google.com (mail-ve0-f180.google.com [209.85.128.180]) by mx.google.com with ESMTPS id uq6si1093733vcb.108.2014.03.28.04.44.06 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 28 Mar 2014 04:44:06 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.128.180 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.180; Received: by mail-ve0-f180.google.com with SMTP id jz11so5465243veb.25 for ; Fri, 28 Mar 2014 04:44:06 -0700 (PDT) X-Received: by 10.52.18.70 with SMTP id u6mr5753683vdd.11.1396007046649; Fri, 28 Mar 2014 04:44:06 -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.12.8 with SMTP id v8csp1627vcv; Fri, 28 Mar 2014 04:44:06 -0700 (PDT) X-Received: by 10.66.231.104 with SMTP id tf8mr8202498pac.48.1396007045728; Fri, 28 Mar 2014 04:44:05 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id sh5si3503151pbc.450.2014.03.28.04.44.04; Fri, 28 Mar 2014 04:44:04 -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 S1752498AbaC1Lnu (ORCPT + 27 others); Fri, 28 Mar 2014 07:43:50 -0400 Received: from mail-wg0-f47.google.com ([74.125.82.47]:54803 "EHLO mail-wg0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751262AbaC1Lnq (ORCPT ); Fri, 28 Mar 2014 07:43:46 -0400 Received: by mail-wg0-f47.google.com with SMTP id x12so3417495wgg.6 for ; Fri, 28 Mar 2014 04:43:45 -0700 (PDT) X-Received: by 10.180.91.164 with SMTP id cf4mr47201164wib.37.1396007025114; Fri, 28 Mar 2014 04:43:45 -0700 (PDT) Received: from localhost ([213.122.173.131]) by mx.google.com with ESMTPSA id bi8sm6449110wib.3.2014.03.28.04.43.40 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Fri, 28 Mar 2014 04:43:44 -0700 (PDT) From: Viresh Kumar To: tglx@linutronix.de Cc: linaro-kernel@lists.linaro.org, linux-kernel@vger.kernel.org, fweisbec@gmail.com, linaro-networking@linaro.org, Arvind.Chauhan@arm.com, Viresh Kumar Subject: [PATCH 16/16] hrtimer: use base->hres_active directly instead of hrtimer_hres_active() Date: Fri, 28 Mar 2014 17:11:35 +0530 Message-Id: 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.180 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: , use base->hres_active directly when we already have a pointer to base instead of calling hrtimer_hres_active(). As that would lead to: __this_cpu_read(hrtimer_bases.hres_active) Signed-off-by: Viresh Kumar --- kernel/hrtimer.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/kernel/hrtimer.c b/kernel/hrtimer.c index 83e5f2d..f379821 100644 --- a/kernel/hrtimer.c +++ b/kernel/hrtimer.c @@ -883,7 +883,7 @@ static void __remove_hrtimer(struct hrtimer *timer, unsigned long newstate, #ifdef CONFIG_HIGH_RES_TIMERS /* Reprogram the clock event device. if enabled */ - if (reprogram && hrtimer_hres_active() && + if (reprogram && base->cpu_base->hres_active && &timer->node == timerqueue_getnext(&base->active)) { ktime_t expires; @@ -1107,7 +1107,7 @@ ktime_t hrtimer_get_next_event(void) raw_spin_lock_irqsave(&cpu_base->lock, flags); - if (!hrtimer_hres_active()) { + if (!cpu_base->hres_active) { for (i = 0; i < HRTIMER_MAX_CLOCK_BASES; i++, base++) { struct hrtimer *timer; struct timerqueue_node *next; @@ -1437,7 +1437,7 @@ void hrtimer_run_queues(void) struct hrtimer_clock_base *base; int index, gettime = 1; - if (hrtimer_hres_active()) + if (cpu_base->hres_active) return; for (index = 0; index < HRTIMER_MAX_CLOCK_BASES; index++) {