From patchwork Mon Oct 28 07:18:57 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "\(Exiting\) Baolin Wang" X-Patchwork-Id: 177883 Delivered-To: patch@linaro.org Received: by 2002:a92:409a:0:0:0:0:0 with SMTP id d26csp3012643ill; Mon, 28 Oct 2019 00:19:57 -0700 (PDT) X-Google-Smtp-Source: APXvYqxRahRJ7FudOlcByoPdWNz53qgojdFWh7rCnKSJxY5AxaA/WbbO9rsQ2dCqqEVdWUDC9Mkj X-Received: by 2002:a17:906:5c0e:: with SMTP id e14mr15518252ejq.200.1572247197770; Mon, 28 Oct 2019 00:19:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1572247197; cv=none; d=google.com; s=arc-20160816; b=0OKFyKoCEwbcfJwcqWU5Rfwegkr52Ui3q91EC4hFSX8q/RA7y/nIaeKCjUGbH+fEIi U/50u7cH0ievpXmlMdrI79ujkuya7uUgXVt05loGu92vjKbZiXGJ2OrqiPmW34FZM54h lU4zQQ/1qCIXT0fhrvOdB5u37IsaCnr5qtcP44qeHumefOoHT4bMqRrSscBXNs0RzSrw 35zKn0sp+ZlqrVNQWToxM4t/KyKMBgRFARcuhdIdFIRYyNwbzt09OcR5+4NyQeDVzSSk X+7yPMKE5lILoNvboPd24ugsjEp8LzYXw4efbdohX3fk49Ui6Fb5TWFSLvL5he8Q4+jl aATQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=ssMFBj43632FcWk2CcxAhFxBDGN9BLK5UqZaapoI3EI=; b=J2Lum9nLZoc8+jdIumFVD26CAYIGk9ytbYaA3s+Jb7YLCXcFAeEklKl4WoYvb6Lm6+ yKge1gwt7Kh7KyNy2qqM16vLoL7g8f9fhNgvByaPPWoGHyYf1oeKtGOTrF5EtPYFH/pE JURbdSf7d5DLLSIKAKR0SLLaE3o+0wEdXaAmXA9CEgMyxH6LzKKMsFls43TKH0v89F9A Sq3Snrvs+jNcohtGL3kUxO1DID3vbd6Fn/vsO7Cmt+xZzd0laaxdEw9bUZPi8P0Z/2Uy cToidvHI6YCpDATAjI8+MX0xjtTO52lSLHX1sdcFDeNaH+eC970/kuD9kalJuct7Zd9K rynA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=SrgmiIPW; spf=pass (google.com: best guess record for domain of linux-pm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-pm-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 r9si5529473eju.251.2019.10.28.00.19.57; Mon, 28 Oct 2019 00:19:57 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-pm-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=SrgmiIPW; spf=pass (google.com: best guess record for domain of linux-pm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-pm-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 S1732503AbfJ1HT4 (ORCPT + 10 others); Mon, 28 Oct 2019 03:19:56 -0400 Received: from mail-pf1-f194.google.com ([209.85.210.194]:39658 "EHLO mail-pf1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732514AbfJ1HT4 (ORCPT ); Mon, 28 Oct 2019 03:19:56 -0400 Received: by mail-pf1-f194.google.com with SMTP id v4so6284371pff.6 for ; Mon, 28 Oct 2019 00:19:54 -0700 (PDT) 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 :in-reply-to:references; bh=ssMFBj43632FcWk2CcxAhFxBDGN9BLK5UqZaapoI3EI=; b=SrgmiIPW0C51iZX8hYKQ2hSUsynSut8k+7kzklaDe3hpral131t906w1kTxvTbV5tI 3AJFcoHHfri+SAsbQwrHOkCumk9s5R6sxf0Lsy79Eu3J5KBusj0Cen9tu0V/2wqWGbOH RETMM4ndBRk1j1in/GGXg8h7nnVqMSf39k7vZ9ymw67v30mM/OouHrZs1i+tJqqJyyOF E3KORbX1/MWIMAzbqYg5QFuWzs2eufjGB9AgaqQiuXq3TcGvlFZyGGOLnDd9ObkzVP+4 sNMQvk6FIeWdhMOwKBK32SKHR1/sO5Itv7GXMlIUpon3uADMjv1Nqvuf//N/tlfER0f+ 1T/g== 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:in-reply-to :references:in-reply-to:references; bh=ssMFBj43632FcWk2CcxAhFxBDGN9BLK5UqZaapoI3EI=; b=WG/4x8SIh1Dl/qjIJpMukFcQKiSLAAEZyEtjOzUdc/5/4IxZAAMkMH523QJ1rha1cO Kb8BhNO6fjnixxi0oweiGcqDWHY/4uCEF2oqCQAclEk3hu/9RfwYd/snXwz23XHkTF6z GZcRYsTk6C+tFanxjnT5D3XdYe2xl/kW5LnTfYTcVY3/uykc4oPjCZVwqcq3ZwMrNV/L /g4GHFT8pTKdFD0yppnk/4fUrxZ8inWgMl6Z6OfUhNUY+ttr/iebxW5AX+x7neJEe5De dEPxBHQZiVaADljJlIaQbO9XvcnF3CWjCGM4o/6At2Jat5Quogu46UWYRnKxZKBYXMxv dsJA== X-Gm-Message-State: APjAAAV+LXmwgOcw0/eodyKG8g2T8OtxQ9OPDCpjchM8u70JRJdeOeAv YZzt7T2ESpbx5hb1Vo1Ogp129Q== X-Received: by 2002:a17:90b:f10:: with SMTP id br16mr20271382pjb.111.1572247194072; Mon, 28 Oct 2019 00:19:54 -0700 (PDT) Received: from baolinwangubtpc.spreadtrum.com ([117.18.48.82]) by smtp.gmail.com with ESMTPSA id 13sm11504703pgq.72.2019.10.28.00.19.50 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 28 Oct 2019 00:19:53 -0700 (PDT) From: Baolin Wang To: sre@kernel.org, robh+dt@kernel.org, mark.rutland@arm.com Cc: linux-pm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, yuanjiang.yu@unisoc.com, baolin.wang@linaro.org, baolin.wang7@gmail.com, zhang.lyra@gmail.com, orsonzhai@gmail.com Subject: [PATCH 1/5] dt-bindings: power: Introduce one property to describe the battery resistance with temperature changes Date: Mon, 28 Oct 2019 15:18:57 +0800 Message-Id: <44f0c19510c7317cb4ee6cac54b3adfa81c2d6d0.1572245011.git.baolin.wang@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: References: In-Reply-To: References: Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org Since the battery internal resistance can be changed as the temperature changes, thus add one table to describe the battery resistance percent in different temperature to get a accurate battery internal resistance. Signed-off-by: Baolin Wang --- .../devicetree/bindings/power/supply/battery.txt | 5 +++++ 1 file changed, 5 insertions(+) -- 1.7.9.5 diff --git a/Documentation/devicetree/bindings/power/supply/battery.txt b/Documentation/devicetree/bindings/power/supply/battery.txt index 5c913d4c..1a6f951 100644 --- a/Documentation/devicetree/bindings/power/supply/battery.txt +++ b/Documentation/devicetree/bindings/power/supply/battery.txt @@ -35,6 +35,10 @@ Optional Properties: for each of the battery capacity lookup table. The first temperature value specifies the OCV table 0, and the second temperature value specifies the OCV table 1, and so on. + - resistance-temp-table: An array providing the resistance percent and + corresponding temperature in degree Celsius, which is used to look up the + resistance percent according to current temperature to get a accurate + batterty internal resistance. Battery properties are named, where possible, for the corresponding elements in enum power_supply_property, defined in @@ -61,6 +65,7 @@ Example: ocv-capacity-table-0 = <4185000 100>, <4113000 95>, <4066000 90>, ...; ocv-capacity-table-1 = <4200000 100>, <4185000 95>, <4113000 90>, ...; ocv-capacity-table-2 = <4250000 100>, <4200000 95>, <4185000 90>, ...; + resistance-temp-table = <20 100>, <10 90>, <0 80>, <(-10) 60>; }; charger: charger@11 {