From patchwork Thu Oct 27 08:04:33 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rajendra Nayak X-Patchwork-Id: 4847 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 B3B8A23E04 for ; Thu, 27 Oct 2011 08:05:15 +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 A86B6A1841C for ; Thu, 27 Oct 2011 08:05:15 +0000 (UTC) Received: by mail-fx0-f52.google.com with SMTP id n26so3439096faa.11 for ; Thu, 27 Oct 2011 01:05:15 -0700 (PDT) Received: by 10.223.16.82 with SMTP id n18mr65036341faa.2.1319702715573; Thu, 27 Oct 2011 01:05:15 -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.1.71 with SMTP id 7cs37175lak; Thu, 27 Oct 2011 01:05:15 -0700 (PDT) Received: by 10.100.246.22 with SMTP id t22mr193136anh.45.1319702714431; Thu, 27 Oct 2011 01:05:14 -0700 (PDT) Received: from comal.ext.ti.com (comal.ext.ti.com. [198.47.26.152]) by mx.google.com with ESMTPS id o6si1910831anb.60.2011.10.27.01.05.13 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 27 Oct 2011 01:05:14 -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 dlep34.itg.ti.com ([157.170.170.115]) by comal.ext.ti.com (8.13.7/8.13.7) with ESMTP id p9R85DXb011674 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 27 Oct 2011 03:05:13 -0500 Received: from dlep26.itg.ti.com (smtp-le.itg.ti.com [157.170.170.27]) by dlep34.itg.ti.com (8.13.7/8.13.8) with ESMTP id p9R85CTQ015233; Thu, 27 Oct 2011 03:05:12 -0500 (CDT) Received: from DLEE74.ent.ti.com (localhost [127.0.0.1]) by dlep26.itg.ti.com (8.13.8/8.13.8) with ESMTP id p9R85Cub015570; Thu, 27 Oct 2011 03:05:12 -0500 (CDT) Received: from dlelxv22.itg.ti.com (172.17.1.197) by DLEE74.ent.ti.com (157.170.170.8) with Microsoft SMTP Server id 14.1.323.3; Thu, 27 Oct 2011 03:05:12 -0500 Received: from ula0131687.itg.ti.com (h108-29.vpn.ti.com [172.24.108.29]) by dlelxv22.itg.ti.com (8.13.8/8.13.8) with ESMTP id p9R84gwV001155; Thu, 27 Oct 2011 03:05:02 -0500 From: Rajendra Nayak To: , CC: , , , , , , , Rajendra Nayak Subject: [PATCH 2/3] omap4: sdp: Pass regulator data from dt Date: Thu, 27 Oct 2011 13:34:33 +0530 Message-ID: <1319702674-16304-3-git-send-email-rnayak@ti.com> X-Mailer: git-send-email 1.7.1 In-Reply-To: <1319702674-16304-1-git-send-email-rnayak@ti.com> References: <1319702674-16304-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 | 57 ++++++++++++++++++++ arch/arm/boot/dts/omap4-sdp.dts | 36 ++++++++++++ 2 files changed, 93 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..2b0842c --- /dev/null +++ b/Documentation/devicetree/bindings/regulator/twl-regulator.txt @@ -0,0 +1,57 @@ +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>; + }; diff --git a/arch/arm/boot/dts/omap4-sdp.dts b/arch/arm/boot/dts/omap4-sdp.dts index 2990841..adc7faf 100644 --- a/arch/arm/boot/dts/omap4-sdp.dts +++ b/arch/arm/boot/dts/omap4-sdp.dts @@ -48,6 +48,42 @@ compatible = "ti,twl4030-rtc"; interrupts = <11>; }; + + vaux1: regulator@0 { + compatible = "ti,twl6030-vaux1","ti,twl6030"; + regulator-min-uV = <1000000>; + regulator-max-uV = <3000000>; + }; + + vaux2: regulator@1 { + compatible = "ti,twl6030-vaux2","ti,twl6030"; + regulator-min-uV = <1200000>; + regulator-max-uV = <2800000>; + }; + + vaux3: regulator@2 { + compatible = "ti,twl6030-vaux3","ti,twl6030"; + regulator-min-uV = <1000000>; + regulator-max-uV = <3000000>; + }; + + vmmc: regulator@3 { + compatible = "ti,twl6030-vmmc","ti,twl6030"; + regulator-min-uV = <1200000>; + regulator-max-uV = <3000000>; + }; + + vpp: regulator@4 { + compatible = "ti,twl6030-vpp","ti,twl6030"; + regulator-min-uV = <1800000>; + regulator-max-uV = <2500000>; + }; + + vusim: regulator@5 { + compatible = "ti,twl6030-vusim","ti,twl6030"; + regulator-min-uV = <1200000>; + regulator-max-uV = <2900000>; + }; }; };