From patchwork Wed Jan 6 08:30:23 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Leo Yan X-Patchwork-Id: 59224 Delivered-To: patch@linaro.org Received: by 10.112.130.2 with SMTP id oa2csp6441089lbb; Wed, 6 Jan 2016 00:31:05 -0800 (PST) X-Received: by 10.98.13.14 with SMTP id v14mr140691925pfi.21.1452069064739; Wed, 06 Jan 2016 00:31:04 -0800 (PST) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l70si79341848pfb.58.2016.01.06.00.31.04; Wed, 06 Jan 2016 00:31:04 -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; 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; dkim=neutral (body hash did not verify) header.i=@linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752571AbcAFIa4 (ORCPT + 29 others); Wed, 6 Jan 2016 03:30:56 -0500 Received: from mail-pa0-f49.google.com ([209.85.220.49]:36528 "EHLO mail-pa0-f49.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752508AbcAFIav (ORCPT ); Wed, 6 Jan 2016 03:30:51 -0500 Received: by mail-pa0-f49.google.com with SMTP id yy13so137414960pab.3 for ; Wed, 06 Jan 2016 00:30:51 -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=UnWvJtX7boEVI8JRJwvilcfW5yE59FDeVHAgAx8vIiXTMXw5hRFdoOGYg1S2h3vzWf j9nESeGNHobW9hsMm7g6m16vTnQTwnL3xWmmTqw1zo4XLOC0ZQvf1v85bhWGmwVmUeBb 0FZesQGX8ICtWliVuDeHA5NC3uZcaq/qov22g= 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=D/hCKpFpOwIJrfb9ljIH4uTL1kZWONMm/jCmabiK/sVk8+uScxJESZG0A20C+Dk1Q5 e1Zo7VrYuuRV7Ym+Vsk7PkzlE/mnNYHhyHQGSXLm6gWmqHpHkGlRNpYwgJW3C/7ZrVwJ 5PTmrA8TwAVPVF90LJmD3fI80ljruevaXP/ZXO0K+C/EkV8E7r55+LQcCiWqDlvPZOyJ SQYuq9pwDgFvPQ5pD+whu920LnQpxCyud4F/APQSoPiwVVZ+kL6Q3+aiZUJ/GsNt5CAI OMpjn5wNLWnZeVkpCzxvPMzSwwX7bbc0GmnfTWuQu6js502whQX+B9fH8zujM86gvkih xx4A== X-Gm-Message-State: ALoCoQk6Gt10nL4rCZJZGoFIZ7XnUyx+e9ieJyaOltT2BLMPIAVkrYk7SgjrcfnzvUss9jcRSBQ0MQsCriNujS8eDGJXKI+qjg== X-Received: by 10.66.102.106 with SMTP id fn10mr73628948pab.60.1452069050911; Wed, 06 Jan 2016 00:30:50 -0800 (PST) Received: from localhost.localdomain (v17.blockcn.net. [192.241.236.26]) by smtp.gmail.com with ESMTPSA id f24sm133416478pff.68.2016.01.06.00.30.47 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 06 Jan 2016 00:30:49 -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 v2 4/4] thermal: power_allocator: document k_pu_ratio/k_po_ratio Date: Wed, 6 Jan 2016 16:30:23 +0800 Message-Id: <1452069023-32149-5-git-send-email-leo.yan@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1452069023-32149-1-git-send-email-leo.yan@linaro.org> References: <1452069023-32149-1-git-send-email-leo.yan@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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(-) -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ 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: