From patchwork Wed Jan 6 08:53:48 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Leo Yan X-Patchwork-Id: 7965421 X-Patchwork-Delegate: rui.zhang@intel.com Return-Path: X-Original-To: patchwork-linux-pm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id CC1659F1CC for ; Wed, 6 Jan 2016 08:54:58 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id E8CD62011D for ; Wed, 6 Jan 2016 08:54:57 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id DDF98200E0 for ; Wed, 6 Jan 2016 08:54:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752365AbcAFIya (ORCPT ); Wed, 6 Jan 2016 03:54:30 -0500 Received: from mail-pf0-f170.google.com ([209.85.192.170]:33912 "EHLO mail-pf0-f170.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752495AbcAFIy0 (ORCPT ); Wed, 6 Jan 2016 03:54:26 -0500 Received: by mail-pf0-f170.google.com with SMTP id e65so182521998pfe.1 for ; Wed, 06 Jan 2016 00:54:26 -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:in-reply-to:references; bh=S+L7ukzqAjdfg/0nJNeK17E/q5e9EgESBrN2/33XtA4=; b=RcXMmQMoRf/IKkitZu0m7fLSTprnLkiR1s50zug62gZL3lc9yTpCNKw6t9jJA+IIxd mDvBm/qfruwHzppIw0djnngNW6p4LOf1sagLDVhO9BE8+uiGxlSXV6A1/PJlziLW13ll 0wYK0aA77W0C73IeUtxA2KrWmuEzTOZrJyHMY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=S+L7ukzqAjdfg/0nJNeK17E/q5e9EgESBrN2/33XtA4=; b=C2/A1p3D71HNdq+X1W+qSBLMqBrUxvxVWABrK6EyzMtzJ+/dmAfKvns4erk59ShAax oBsgRo/Z3xjhFKeFoKsdulNkT8btCovOOp7Yj6eQBatCTueXR+8lei3Lw/jUwa4zUTNP P6K1bHcHmUDq34rvUEt7/Jzrl18kHL/hdxzonQTV4l1uUoO0FO+2PCa3z9+1TSfg+5AP qFM/Wba8kDWcS4kTX5EM5n87Syvltoo4N+j1Xp71nOyIfoA1PjllYrgurLb7g0iUM5im qYLc8kotctwfnZMYa/Ix4mP7WD+nc3HwvqimQDkFchvDrQE/+fLGK3kPd4QiSTFCR1fi tnAg== X-Gm-Message-State: ALoCoQkVxsp1br6IZotdgQoLdJA4hKGmfsiEJ+lQPB2p67GufLFEi/GemYJlLIsOXT5SLz1EF5d+3xQkzbdhNltqSyhkAOztcA== X-Received: by 10.98.7.210 with SMTP id 79mr139481983pfh.98.1452070465935; Wed, 06 Jan 2016 00:54:25 -0800 (PST) Received: from localhost.localdomain (v17.blockcn.net. [192.241.236.26]) by smtp.gmail.com with ESMTPSA id ux2sm138843233pac.46.2016.01.06.00.54.21 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 06 Jan 2016 00:54:24 -0800 (PST) From: Leo Yan To: Jonathan Corbet , Zhang Rui , Eduardo Valentin , Javi Merino , Punit Agrawal , Daniel Kurtz , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org, Daniel Thompson Cc: Leo Yan Subject: [PATCH v3 4/4] thermal: power_allocator: document k_pu_ratio/k_po_ratio Date: Wed, 6 Jan 2016 16:53:48 +0800 Message-Id: <1452070428-2567-5-git-send-email-leo.yan@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1452070428-2567-1-git-send-email-leo.yan@linaro.org> References: <1452070428-2567-1-git-send-email-leo.yan@linaro.org> Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Document k_pu_ratio and k_po_ratio's purpose, and refine formula to demonstrate to use ratio to calculate k_pu/k_po. Signed-off-by: Leo Yan --- Documentation/thermal/power_allocator.txt | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/Documentation/thermal/power_allocator.txt b/Documentation/thermal/power_allocator.txt index a1ce223..8958dab 100644 --- a/Documentation/thermal/power_allocator.txt +++ b/Documentation/thermal/power_allocator.txt @@ -114,13 +114,20 @@ whilst temperature is low, and may lead to temperature overshooting. The default value for `k_pu` is: - 2 * sustainable_power / (desired_temperature - switch_on_temp) + k_pu_ratio * sustainable_power / (desired_temperature - switch_on_temp) This means that at `switch_on_temp` the output of the controller's -proportional term will be 2 * `sustainable_power`. The default value -for `k_po` is: +proportional term will be k_pu_ratio * `sustainable_power`. - sustainable_power / (desired_temperature - switch_on_temp) +The default value for `k_po` is: + + k_po_ratio * sustainable_power / (desired_temperature - switch_on_temp) + +k_pu_ratio's default value is 2 and k_po_ratio's default value is 1. +These two vairants mean the ratio value compared against sustainable power, +so smaller ratio will result in thermal slower ramp. User can set these two +ratio value from sys filesystem nodes, finally k_pu and k_po will be +calculated by updated ratio value. Focusing on the proportional and feed forward values of the PID controller equation we have: