From patchwork Tue Sep 27 10:12:46 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rajendra Nayak X-Patchwork-Id: 4370 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 0CFF523F6F for ; Tue, 27 Sep 2011 10:13:36 +0000 (UTC) Received: from mail-fx0-f52.google.com (mail-fx0-f52.google.com [209.85.161.52]) by fiordland.canonical.com (Postfix) with ESMTP id 00594A18065 for ; Tue, 27 Sep 2011 10:13:35 +0000 (UTC) Received: by mail-fx0-f52.google.com with SMTP id 23so9690167fxe.11 for ; Tue, 27 Sep 2011 03:13:35 -0700 (PDT) Received: by 10.223.63.8 with SMTP id z8mr12161905fah.84.1317118415894; Tue, 27 Sep 2011 03:13:35 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.152.3.234 with SMTP id f10cs67268laf; Tue, 27 Sep 2011 03:13:35 -0700 (PDT) Received: by 10.236.78.200 with SMTP id g48mr47554154yhe.12.1317118412280; Tue, 27 Sep 2011 03:13:32 -0700 (PDT) Received: from comal.ext.ti.com (comal.ext.ti.com. [198.47.26.152]) by mx.google.com with ESMTPS id r70si24445743yhm.145.2011.09.27.03.13.31 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 27 Sep 2011 03:13:32 -0700 (PDT) Received-SPF: pass (google.com: domain of rnayak@ti.com designates 198.47.26.152 as permitted sender) client-ip=198.47.26.152; Authentication-Results: mx.google.com; spf=pass (google.com: domain of rnayak@ti.com designates 198.47.26.152 as permitted sender) smtp.mail=rnayak@ti.com Received: from dbdp20.itg.ti.com ([172.24.170.38]) by comal.ext.ti.com (8.13.7/8.13.7) with ESMTP id p8RADJvC027643 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 27 Sep 2011 05:13:21 -0500 Received: from dbde70.ent.ti.com (localhost [127.0.0.1]) by dbdp20.itg.ti.com (8.13.8/8.13.8) with ESMTP id p8RADIgj024575; Tue, 27 Sep 2011 15:43:18 +0530 (IST) Received: from dbdp31.itg.ti.com (172.24.170.98) by DBDE70.ent.ti.com (172.24.170.148) with Microsoft SMTP Server id 8.3.106.1; Tue, 27 Sep 2011 15:43:18 +0530 Received: from ula0131687.apr.dhcp.ti.com (ula0131687-172024137082.apr.dhcp.ti.com [172.24.137.82]) by dbdp31.itg.ti.com (8.13.8/8.13.8) with ESMTP id p8RAD81K019725; Tue, 27 Sep 2011 15:43:18 +0530 (IST) From: Rajendra Nayak To: , CC: , , , , , , , Rajendra Nayak Subject: [PATCH 3/9] omap4: sdp: Pass regulator data from dt Date: Tue, 27 Sep 2011 15:42:46 +0530 Message-ID: <1317118372-17052-4-git-send-email-rnayak@ti.com> X-Mailer: git-send-email 1.7.1 In-Reply-To: <1317118372-17052-1-git-send-email-rnayak@ti.com> References: <1317118372-17052-1-git-send-email-rnayak@ti.com> MIME-Version: 1.0 Pass adjustable regulator information for omap4sdp from device tree so the regulator driver can then use the regulator helper routine to extract and use them during the driver probe(). Also add documentation for TWL regulator specific bindings. Signed-off-by: Rajendra Nayak --- .../bindings/regulator/twl-regulator.txt | 60 ++++++++++++++++++ arch/arm/boot/dts/omap4-sdp.dts | 64 ++++++++++++++++++++ 2 files changed, 124 insertions(+), 0 deletions(-) create mode 100644 Documentation/devicetree/bindings/regulator/twl-regulator.txt diff --git a/Documentation/devicetree/bindings/regulator/twl-regulator.txt b/Documentation/devicetree/bindings/regulator/twl-regulator.txt new file mode 100644 index 0000000..7b809ff --- /dev/null +++ b/Documentation/devicetree/bindings/regulator/twl-regulator.txt @@ -0,0 +1,60 @@ +TWL family of regulators + +Required properties: +- compatible: + - "ti,twl4030" for twl4030 regulators + - "ti,twl6025" for twl6025 regulators + - "ti,twl6030" for twl6030 regulators + +Additionally compatible can be used to specify the +exact regulator/ldo instance like +For twl6030 regulators/LDO's +- compatible: + - "ti,twl6030-vaux1" for VAUX1 LDO + - "ti,twl6030-vaux2" for VAUX2 LDO + - "ti,twl6030-vaux3" for VAUX3 LDO + - "ti,twl6030-vmmc" for VMMC LDO + - "ti,twl6030-vpp" for VPP LDO + - "ti,twl6030-vusim" for VUSIM LDO +For twl6025 regulators/LDO's +- compatible: + - "ti,twl6025-ldo1" for LDO1 LDO + - "ti,twl6025-ldo2" for LDO2 LDO + - "ti,twl6025-ldo3" for LDO3 LDO + - "ti,twl6025-ldo4" for LDO4 LDO + - "ti,twl6025-ldo5" for LDO5 LDO + - "ti,twl6025-ldo6" for LDO6 LDO + - "ti,twl6025-ldo7" for LDO7 LDO + - "ti,twl6025-ldoln" for LDOLN LDO + - "ti,twl6025-ldousb" for LDOUSB LDO +For twl4030 regulators/LDO's +- compatible: + - "ti,twl4030-vaux1" for VAUX1 LDO + - "ti,twl4030-vaux2" for VAUX2 LDO + - "ti,twl5030-vaux2" for VAUX2 LDO + - "ti,twl4030-vaux3" for VAUX3 LDO + - "ti,twl4030-vaux4" for VAUX4 LDO + - "ti,twl4030-vmmc1" for VMMC1 LDO + - "ti,twl4030-vmmc2" for VMMC2 LDO + - "ti,twl4030-vpll1" for VPLL1 LDO + - "ti,twl4030-vpll2" for VPLL2 LDO + - "ti,twl4030-vsim" for VSIM LDO + - "ti,twl4030-vdac" for VDAC LDO + - "ti,twl4030-vintana2" for VINTANA2 LDO + - "ti,twl4030-vio" for VIO LDO + - "ti,twl4030-vdd1" for VDD1 LDO + - "ti,twl4030-vdd2" for VDD2 LDO + +Optional properties: +- Any optional property defined in bindings/regulator/regulator.txt + +Example: + + xyz: regulator@0 { + compatible = "ti,twl6030-vaux1","ti,twl6030"; + regulator-min_uV = <1000000>; + regulator-max_uV = <3000000>; + regulator-more-normal; + regulator-mode-standby; + regulator-change-voltage; + }; diff --git a/arch/arm/boot/dts/omap4-sdp.dts b/arch/arm/boot/dts/omap4-sdp.dts index 2990841..edbf77e 100644 --- a/arch/arm/boot/dts/omap4-sdp.dts +++ b/arch/arm/boot/dts/omap4-sdp.dts @@ -48,6 +48,70 @@ compatible = "ti,twl4030-rtc"; interrupts = <11>; }; + + vaux1: regulator@0 { + compatible = "ti,twl6030-vaux1","ti,twl6030"; + regulator-min-uV = <1000000>; + regulator-max-uV = <3000000>; + regulator-mode-normal; + regulator-mode-standby; + regulator-change-voltage; + regulator-change-mode; + }; + + vaux2: regulator@1 { + compatible = "ti,twl6030-vaux2","ti,twl6030"; + regulator-min-uV = <1200000>; + regulator-max-uV = <2800000>; + regulator-mode-normal; + regulator-mode-standby; + regulator-change-mode; + regulator-change-status; + regulator-change-voltage; + }; + + vaux3: regulator@2 { + compatible = "ti,twl6030-vaux3","ti,twl6030"; + regulator-min-uV = <1000000>; + regulator-max-uV = <3000000>; + regulator-mode-normal; + regulator-mode-standby; + regulator-change-mode; + regulator-change-status; + regulator-change-voltage; + }; + + vmmc: regulator@3 { + compatible = "ti,twl6030-vmmc","ti,twl6030"; + regulator-min-uV = <1200000>; + regulator-max-uV = <3000000>; + regulator-mode-normal; + regulator-mode-standby; + regulator-change-mode; + regulator-change-status; + regulator-change-voltage; + }; + + vpp: regulator@4 { + compatible = "ti,twl6030-vpp","ti,twl6030"; + regulator-min-uV = <1800000>; + regulator-max-uV = <2500000>; + regulator-mode-normal; + regulator-mode-standby; + regulator-change-mode; + regulator-change-status; + regulator-change-voltage; + }; + + vusim: regulator@5 { + compatible = "ti,twl6030-vusim","ti,twl6030"; + regulator-min-uV = <1200000>; + regulator-max-uV = <2900000>; + regulator-mode-normal; + regulator-mode-standby; + regulator-change-voltage; + regulator-change-mode; + }; }; };