From patchwork Tue Jan 22 14:24:28 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vincent Guittot X-Patchwork-Id: 156298 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp7638347jaa; Tue, 22 Jan 2019 06:24:38 -0800 (PST) X-Google-Smtp-Source: ALg8bN4CITNoBXjxw7k8A0eF8zGQ2PvLXkKztAXXcmdkOpfbuPe/Da/X06NigufK/gLc8peLwoDb X-Received: by 2002:a17:902:7882:: with SMTP id q2mr35449435pll.305.1548167078671; Tue, 22 Jan 2019 06:24:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548167078; cv=none; d=google.com; s=arc-20160816; b=PfKOFV1bxmLmx6OPbxghUgq1E05DlVEvSS4m9egqUl/cS5K7+BtUAniW68CpeJDbJz FlQiLkktOJkcxKhAurI7E374O7saUhyJMlWvVhdsvmEhfIEj55cDDTsAyGLSzBnjF9yz vOhLVB/D6VDlpF+xMYLCzP6DIA13DA3ybuZeGA1ET4P6VOaDEnfOFa4RyS6SCxKHzHCv FaSjlMAIyFKenQ0cP1UxIVaBGkTLU9r3+URScxU6gwJ/h0R3K2NvNyNKTuiIAsTBvosf 7Z80NHjTzNY9nnw1Rh6lJxypyqQgFDTiLc3mCod7F6p1lvlmL1G/eD6QSdaLWylfYrVG cGFA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature; bh=itJxEXH4FREUUJIjo2Nj5mSOkQ/lHsZ5PO5eWoAOnes=; b=DWxh8HsZFLD6sgexvn/iqEzHh+d1P9EcAQu1J79Lr6jLbDzbfINZWRiC/rtolW/oS4 +aC1KRmrjmzhMCueJEFtOyBLal6WElzvoG6uua9JMMKrLuaaYsR9AiubvA78h0WiuUIF ZWUjMhWedhee2YnN4A+F6hx8mPcbhz4KoSylmaopua7XTJ7d0HERx54C5U1by/kG+rJE cx7RmMhN1OncqD0cOppXsLCXO5hZCl1YYWaBtAtUrsmF+v8hX4+qw85Q6tJAxqQ7/Vc4 li5kpXAyFwfgeJr3gcAhtIcoBSwezR/fD1LmPkyUOOkpdGaiwpcZchA2H0TKQevJ4/MF Oiiw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="ifog/VvV"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u6si205104pfb.92.2019.01.22.06.24.38; Tue, 22 Jan 2019 06:24:38 -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; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="ifog/VvV"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728715AbfAVOYf (ORCPT + 26 others); Tue, 22 Jan 2019 09:24:35 -0500 Received: from mail-wr1-f66.google.com ([209.85.221.66]:33493 "EHLO mail-wr1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728511AbfAVOYf (ORCPT ); Tue, 22 Jan 2019 09:24:35 -0500 Received: by mail-wr1-f66.google.com with SMTP id c14so27622818wrr.0 for ; Tue, 22 Jan 2019 06:24:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=itJxEXH4FREUUJIjo2Nj5mSOkQ/lHsZ5PO5eWoAOnes=; b=ifog/VvVKSzamOglbvzQKyLRYfoPQZjgsjivGhOU3qepRjuAvfEVi5kWGCOA++8dZF mSN93tXGL75N4KdizMdlD1GWTsnxbyoXLin2UsEnI/yb0Sht3wUVfZdggnrYPIJEVzlD fDkTaaqynPP33O2QMEoJY910GgJ4Sxojx7XaM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=itJxEXH4FREUUJIjo2Nj5mSOkQ/lHsZ5PO5eWoAOnes=; b=RJqHTPf247p14eUWN1n5UWteRiCX/AdqUvLmgGlgp4qam6vmTEXL/w5sXJDdJendHC wKfETQLknRA0F/XmvIv7IQFHZPuRW7+NKE2kqdVLteCpFdY/bp02PNXsu9N1aXFYJndh 9M+e6mSwIPH61pX+CTpKvyBW66iSvbNvMSZvvWvH+1EUhn0g/B/BDfVs9MVdg4FBmWK8 Vjy16b7pzoLJ0abAkykje3RTGlI7EFgGd0n1BJLGNLD+Glmszy+jHPFEfQj7bnrPGwZ7 0ooEGAt2q7R8aylKvkXtv9WuIEo6BcH2axxPejYVi5z6rzoUMIcyoYCRgrxiGsgvytps llGA== X-Gm-Message-State: AJcUukeUPCQxJewAUAzzlgi2qjCR0/1sh1YTq06Kil85D5dGMP8DX2yS B8K3EqgVtmUsiOY7aKNncoT7Fg== X-Received: by 2002:adf:a393:: with SMTP id l19mr34079911wrb.110.1548167073481; Tue, 22 Jan 2019 06:24:33 -0800 (PST) Received: from localhost.localdomain ([2a01:e0a:f:6020:609f:7896:d361:50c6]) by smtp.gmail.com with ESMTPSA id l19sm52620119wme.21.2019.01.22.06.24.32 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 22 Jan 2019 06:24:32 -0800 (PST) From: Vincent Guittot To: linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, rjw@rjwysocki.net, thara.gopinath@linaro.org, linux@roeck-us.net Cc: ulf.hansson@linaro.org, Vincent Guittot Subject: [PATCH v6 0/3] Move pm_runtime accounted time to raw nsec Date: Tue, 22 Jan 2019 15:24:28 +0100 Message-Id: <1548167070-421-1-git-send-email-vincent.guittot@linaro.org> X-Mailer: git-send-email 2.7.4 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Move pm_runtime accounted time to raw nsec. The subject of the patchset has changed as the 1st patch of the previous versions has been queued by Rafael. Patch 1 set accounting_timestamp to 0 in pm_runtime_init and update it when enable. So we remove ordering constraint between timekeeping_init and pm_runtime_init Patch 2 moves time accounting on raw ns. This patch initially used ktime instead of raw ns but it was easier to move i915 driver on raw ns than on ktime. Changes since v5: - removed patches already queued. - set accounting_timestamp to 0 in pm_runtime_init and update it when enable Changes since v4: -Update commit message Changes since v3: - Rebase on v4.20-rc7 without patch that has been queued by Rafael - Simplify the new interface pm_runtime_suspended_time() Changes since v2: - remove patch1 that has been queued by rafael - add new interface in pm_runtime to get accounted time - reorder patchset to prevent compilation error Changes since v1: - updated commit message of patch 1 - Added patches 2 & 3 to move runtime_pm accounting on raw ns Thara Gopinath (1): PM-runtime: Replace jiffies based accounting with ktime-based accounting Vincent Guittot (1): PM-runtime: update accounting_timestamp only when enable drivers/base/power/runtime.c | 21 +++++++++++++-------- drivers/base/power/sysfs.c | 11 ++++++++--- include/linux/pm.h | 6 +++--- 3 files changed, 24 insertions(+), 14 deletions(-) -- 2.7.4