From patchwork Mon Feb 24 06:29:37 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tuukka Tikkanen X-Patchwork-Id: 25177 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ig0-f197.google.com (mail-ig0-f197.google.com [209.85.213.197]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id D1F452066C for ; Mon, 24 Feb 2014 08:14:05 +0000 (UTC) Received: by mail-ig0-f197.google.com with SMTP id uy17sf10392699igb.0 for ; Mon, 24 Feb 2014 00:14:05 -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:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=rDdKYnP2Y4hkX6I6bKt+pGGP1bTV0Xry+a0P4Kdjy0c=; b=E00gkWUOsycfs8NeIJ6tcwmrXqWN1ylT6LcCJr+dwHuySSklukQLiK8pwwjXyA1GYS ZeHCkyLoWr8RZGdeSSb0teEsKfRqWdxv7mE1q7vdBd/drxIwWcBUmj86Tcp6g2v/PSPe 38/8Ky+KRQ7lbibsynCix4NP8BIFXPehdflmPM8A38U8wChQDaqaAONi/ZU9HC4gFUr3 6ydLrIyrFXZuR1K/CP49CihdfOdVSK3BaSJqdhqH0rNkBjmRKowwEf5DcSVndj801WCX iOte6dKCQxv17mGDZpEisqYVueAChz/KTUVmZYsfLMqMKUiyL9Jq84VeDaH9L/kzXP38 D3rA== X-Gm-Message-State: ALoCoQnkoQtWq775Q+CqkYZFNhIEUR3UW8dN++jFhA+xbwaBJ6sTAUq7NkWSOwAH8LuIJou1vhU7 X-Received: by 10.42.240.19 with SMTP id ky19mr9202927icb.4.1393229645358; Mon, 24 Feb 2014 00:14:05 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.104.142 with SMTP id a14ls526676qgf.31.gmail; Mon, 24 Feb 2014 00:14:05 -0800 (PST) X-Received: by 10.52.251.232 with SMTP id zn8mr9467673vdc.41.1393229645220; Mon, 24 Feb 2014 00:14:05 -0800 (PST) Received: from mail-vc0-f176.google.com (mail-vc0-f176.google.com [209.85.220.176]) by mx.google.com with ESMTPS id xn5si5640186vdc.29.2014.02.24.00.14.05 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 24 Feb 2014 00:14:05 -0800 (PST) Received-SPF: neutral (google.com: 209.85.220.176 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.176; Received: by mail-vc0-f176.google.com with SMTP id la4so5361618vcb.7 for ; Mon, 24 Feb 2014 00:14:05 -0800 (PST) X-Received: by 10.221.26.10 with SMTP id rk10mr11747315vcb.0.1393229645143; Mon, 24 Feb 2014 00:14:05 -0800 (PST) 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.174.196 with SMTP id u4csp44747vcz; Mon, 24 Feb 2014 00:14:04 -0800 (PST) X-Received: by 10.66.191.42 with SMTP id gv10mr23669697pac.125.1393229644332; Mon, 24 Feb 2014 00:14:04 -0800 (PST) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id xz2si12080128pbb.179.2014.02.24.00.14.03; Mon, 24 Feb 2014 00:14:03 -0800 (PST) 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 S1753357AbaBXINH (ORCPT + 26 others); Mon, 24 Feb 2014 03:13:07 -0500 Received: from mx.mmd.net ([80.83.0.3]:55414 "EHLO mx.mmd.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752909AbaBXIND (ORCPT ); Mon, 24 Feb 2014 03:13:03 -0500 Received: from istutuskone.tic0.net (verkonrikkoja.tic0.net [80.83.5.104]) by mx.mmd.net (Postfix) with ESMTP id 8204BFE2; Mon, 24 Feb 2014 09:26:37 +0200 (EET) From: Tuukka Tikkanen To: linux-pm@vger.kernel.org, rjw@rjwysocki.net Cc: daniel.lezcano@linaro.org, tuukka.tikkanen@linaro.org, linux-kernel@vger.kernel.org Subject: [PATCH 7/7] Cpuidle: poll state can measure residency Date: Mon, 24 Feb 2014 08:29:37 +0200 Message-Id: <1393223377-5744-8-git-send-email-tuukka.tikkanen@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1393223377-5744-1-git-send-email-tuukka.tikkanen@linaro.org> References: <1393223377-5744-1-git-send-email-tuukka.tikkanen@linaro.org> 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: tuukka.tikkanen@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.176 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: , For some platforms, a poll state is inserted in the cpuidle driver states. The flags for the state do not indicate that timekeeping is not affected. As the state does not do anything apart from calling cpu_relax(), the times returned by ktime_get should remain valid. Add the missing flag. Signed-off-by: Tuukka Tikkanen --- drivers/cpuidle/driver.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/cpuidle/driver.c b/drivers/cpuidle/driver.c index 06dbe7c..136d6a2 100644 --- a/drivers/cpuidle/driver.c +++ b/drivers/cpuidle/driver.c @@ -209,7 +209,7 @@ static void poll_idle_init(struct cpuidle_driver *drv) state->exit_latency = 0; state->target_residency = 0; state->power_usage = -1; - state->flags = 0; + state->flags = CPUIDLE_FLAG_TIME_VALID; state->enter = poll_idle; state->disabled = false; }