From patchwork Mon Mar 9 01:23:11 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Beomho Seo X-Patchwork-Id: 447836 Return-Path: X-Original-To: incoming-dt@patchwork.ozlabs.org Delivered-To: patchwork-incoming-dt@bilbo.ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id C2F47140172 for ; Mon, 9 Mar 2015 12:24:04 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932162AbbCIBXt (ORCPT ); Sun, 8 Mar 2015 21:23:49 -0400 Received: from mailout2.samsung.com ([203.254.224.25]:18686 "EHLO mailout2.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932079AbbCIBXU (ORCPT ); Sun, 8 Mar 2015 21:23:20 -0400 Received: from epcpsbgr1.samsung.com (u141.gpu120.samsung.co.kr [203.254.230.141]) by mailout2.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0NKX00EBE7UVX2B0@mailout2.samsung.com>; Mon, 09 Mar 2015 10:23:19 +0900 (KST) Received: from epcpsbgm2.samsung.com ( [172.20.52.114]) by epcpsbgr1.samsung.com (EPCPMTA) with SMTP id 1D.1D.17016.606FCF45; Mon, 09 Mar 2015 10:23:18 +0900 (KST) X-AuditID: cbfee68d-f79296d000004278-88-54fcf606234e Received: from epmmp2 ( [203.254.227.17]) by epcpsbgm2.samsung.com (EPCPMTA) with SMTP id A5.FB.09430.606FCF45; Mon, 09 Mar 2015 10:23:18 +0900 (KST) Received: from localhost.localdomain ([10.252.81.134]) by mmp2.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0NKX00HDA7USIY30@mmp2.samsung.com>; Mon, 09 Mar 2015 10:23:18 +0900 (KST) From: Beomho Seo To: broonie@kernel.org, robh+dt@kernel.org, pawel.moll@arm.com, mark.rutland@arm.com, ijc+devicetree@hellion.org.uk, galak@codeaurora.org Cc: linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org, devicetree@vger.kernel.org, sre@kernel.org, lee.jones@linaro.org, cw00.choi@samsung.com, sangbae90.lee@samsung.com, inki.dae@samsung.com, sw0312.kim@samsung.com, Beomho Seo Subject: [PATCH 2/2] Documentation: Add documentation for rt5033 multifunction device Date: Mon, 09 Mar 2015 10:23:11 +0900 Message-id: <1425864191-4121-3-git-send-email-beomho.seo@samsung.com> X-Mailer: git-send-email 1.7.9.5 In-reply-to: <1425864191-4121-1-git-send-email-beomho.seo@samsung.com> References: <1425864191-4121-1-git-send-email-beomho.seo@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFprIIsWRmVeSWpSXmKPExsWyRsSkSJft258Qg47VVhanP21jt5j68Amb xfUvz1kt5h85x2rR/2Yhq8W5VysZLSbdn8Bicf/rUUaLy7vmsFl87j3CaLH0+kUmiwnT17JY tO49wm5x/NNBFovTu0ssZkx+yeYg4LFm3hpGj8t9vUweK5d/YfPYtKqTzePOtT1sHn1bVjF6 fN4kF8AexWWTkpqTWZZapG+XwJWxe3kLc8FP9YrNZ3+yNjDeVOhi5OSQEDCR2P/lMguELSZx 4d56ti5GLg4hgaWMEjvWfWWCKfo/bzojRGI6o8SNRcuhnDYmib6Zq1lBqtgENCXeT7nCApIQ EehmlFi/sAFsLrNAO5PElNfBILawQLjEkc9bwMayCKhKXOzeClbDK+AqcWzvKaA4B9A6BYk5 k2xATE4BN4lfE8pAKoSAKi6e+MYMMl5C4C27xM6pR1ggxghIfJt8iAWiVVZi0wFmiKMlJQ6u uMEygVF4ASPDKkbR1ILkguKk9CJDveLE3OLSvHS95PzcTYzAmDr971nvDsbbB6wPMQpwMCrx 8O448SdEiDWxrLgy9xCjKdCGicxSosn5wMjNK4k3NDYzsjA1MTU2Mrc0UxLnVZT6GSwkkJ5Y kpqdmlqQWh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EsPOXnvD8d5X5i17Ljj0LN jQxlxifXNnXHW++dI2MW1763w+NoVsvMn1MfB7qGzt3Xs4o75tQFJZbijERDLeai4kQA5lBB 2O4CAAA= DLP-Filter: Pass X-MTR: 20000000000000000@CPGS X-CFilter-Loop: Reflected Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org This patch device tree binding documentation for rt5033 multifunction device. Cc: Sebastian Reichel Cc: Lee Jones Cc: Mark Brown Cc: Rob Herring Cc: Pawel Moll Cc: Mark Rutland Cc: Ian campbell Cc: Kumar Gala Signed-off-by: Beomho Seo Acked-by: Chanwoo Choi --- Changes in v5 - Remove wrong Acked-by. Changes in v4 - none. Changes in v3 - Add Acked-by Changes in v2 - Fix incorrect typo. - Align -uamp and -uvolt names with regulator binding suffixes. - Drop incorrect phandle. - Fix incorrect example. --- Documentation/devicetree/bindings/mfd/rt5033.txt | 101 ++++++++++++++++++++ .../devicetree/bindings/vendor-prefixes.txt | 1 + 2 files changed, 102 insertions(+) create mode 100644 Documentation/devicetree/bindings/mfd/rt5033.txt diff --git a/Documentation/devicetree/bindings/mfd/rt5033.txt b/Documentation/devicetree/bindings/mfd/rt5033.txt new file mode 100644 index 0000000..64b23e8 --- /dev/null +++ b/Documentation/devicetree/bindings/mfd/rt5033.txt @@ -0,0 +1,101 @@ +Richtek RT5033 Power management Integrated Circuit + +RT5033 is a Multifunction device which includes battery charger, fuel gauge, +flash LED current source, LDO and synchronous Buck converter for portable +applications. It is interfaced to host controller using i2c interface. + +Required properties: +- compatible : Must be "richtek,rt5033" +- reg : Specifies the i2c slave address of general part. +- interrupts : This i2c devices has an IRQ line connected to the main SoC. +- interrupt-parent : The parent interrupt controller. + +Optional node: +Regulators: The regulators of RT5033 have to be instantiated under sub-node +named "regulators" using the following format. + + regulators { + regulator-name { + regulator-name = LDO/BUCK + regulator subnodes called X, Y and Z + }; + }; + refer Documentation/devicetree/bindings/regulator/regulator.txt + + +Battery charger: There battery charger of RT5033 have to be instantiated under +sub-node named "charger" using the following format. + +Required properties: +- compatible : Must be "richtek,rt5033-charger". +- richtek,pre-uamp : Current of pre-charge mode. The pre-charge current levels + are 350 mA to 650 mA programmed by I2C per 100 mA. +- richtek,fast-uamp : Current of fast-charge mode. The fast-charge current + levels are 700 mA to 2000 mA programmed by I2C per 100 mA. +- richtek,eoc-uamp : This property is end of charge current. Its level 150 mA + to 200 mA. +- richtek,pre-threshold-uvolt : Voltage of threshold pre-charge mode. Battery + voltage is below pre-charge threshold voltage, the charger is in pre-charge + mode with pre-charge current. Its levels are 2.3 V to 3.8 V programmed + by I2C per 0.1 V. +- richtek,const-uvolt : Battery regulation voltage of constant voltage mode. + This voltage level 3.65 V to 4.4 V bye I2C per 0.025 V. + + charger { + compatible = "richtek,rt5033-charger"; + richtek,pre-uamp = <350000>; + richtek,fast-uamp = <2000000>; + richtek,eoc-uamp = <250000>; + richtek,pre-threshold-uvolt = <3400000>; + richtek,const-uvolt = <4350000>; + + }; + + +Fuelgauge: There fuelgauge of RT5033 to be instantiated node named "fuelgauge" +using the following format. + +Required properties: +- compatible = Must be "richtek,rt5033-battery". + + rt5033@35 { + compatible = "richtek,rt5033-battery"; + interrupt-parent = <&gpx2>; + interrupts = <3 0>; + reg = <0x35>; + }; + +Example: + + rt5033@34 { + compatible = "richtek,rt5033"; + reg = <0x34>; + interrupt-parent = <&gpx1>; + interrupts = <5 0>; + + regulators { + buck_reg: BUCK { + regulator-name = "BUCK"; + regulator-min-microvolt = <1200000>; + regulator-max-microvolt = <1200000>; + regulator-always-on; + }; + }; + + charger { + compatible = "richtek,rt5033-charger"; + richtek,pre-uamp = <350000>; + richtek,fast-uamp = <2000000>; + richtek,eoc-uamp = <250000>; + richtek,pre-threshold-uvolt = <3400000>; + richtek,const-uvolt = <4350000>; + }; + + }; + + rt5033@35 { + compatible = "richtek,rt5033-battery"; + interrupt-parent = <&gpx2>; + interrupts = <3 0>; + reg = <0x35>; + }; diff --git a/Documentation/devicetree/bindings/vendor-prefixes.txt b/Documentation/devicetree/bindings/vendor-prefixes.txt index 389ca13..73d235a 100644 --- a/Documentation/devicetree/bindings/vendor-prefixes.txt +++ b/Documentation/devicetree/bindings/vendor-prefixes.txt @@ -149,6 +149,7 @@ ralink Mediatek/Ralink Technology Corp. ramtron Ramtron International realtek Realtek Semiconductor Corp. renesas Renesas Electronics Corporation +richtek Richtek Technology Corporation ricoh Ricoh Co. Ltd. rockchip Fuzhou Rockchip Electronics Co., Ltd samsung Samsung Semiconductor