diff mbox

ARM: tegra: enable palmas device for dalmore

Message ID 1373290688-2257-1-git-send-email-ldewangan@nvidia.com (mailing list archive)
State New, archived
Headers show

Commit Message

Laxman Dewangan July 8, 2013, 1:38 p.m. UTC
Make the entry of Dalmore Power Management Unit device TPS65913
in dalmore DTS file. The Palma driver support this device.

Enable following submodule of the TPS65913:
- GPIO driver
- RTC driver.
- Power regulator driver.

Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
---
 arch/arm/boot/dts/tegra114-dalmore.dts |  183 +++++++++++++++++++++++++++++++-
 1 files changed, 182 insertions(+), 1 deletions(-)

Comments

Stephen Warren July 9, 2013, 4:57 p.m. UTC | #1
On 07/08/2013 07:38 AM, Laxman Dewangan wrote:
> Make the entry of Dalmore Power Management Unit device TPS65913
> in dalmore DTS file. The Palma driver support this device.
> 
> Enable following submodule of the TPS65913:
> - GPIO driver
> - RTC driver.
> - Power regulator driver.

> diff --git a/arch/arm/boot/dts/tegra114-dalmore.dts b/arch/arm/boot/dts/tegra114-dalmore.dts

> +		palmas: tps65913@58 {

I assume there's only one TPS65913 in the system, so that node name
doesn't need to contain the unit address to make it unique; the node can
simply be named "tps65913".

> +			palmas_gpio: palmas_gpio {
> +			palmas_rtc {
> +			palmas_pmic {

I don't think those node names need "palmas" in them; they can simply be
"gpio", "rtc", "pmic".


> +			    ldousb-in-supply = <&tps65090_dcdc1_reg>;
> +			    regulators {

You'd usually leave a blank line between properties and nodes.

> +		vdd_cam_1v8_reg: regulator@6 {
...
> +			gpio = <&palmas_gpio 6 0>; /* Palmas GPIO6 */

That comment probably isn't worthwhile; I only insisted on them for
Tegra GPIOs so that the GPIO name could be included somewhere, whereas
for devices with just a small handful of GPIOs without any other names,
there's no point putting a comment, since it's obvious from the cell
content.
diff mbox

Patch

diff --git a/arch/arm/boot/dts/tegra114-dalmore.dts b/arch/arm/boot/dts/tegra114-dalmore.dts
index 886b66d..53f30c0 100644
--- a/arch/arm/boot/dts/tegra114-dalmore.dts
+++ b/arch/arm/boot/dts/tegra114-dalmore.dts
@@ -791,7 +791,7 @@ 
 					regulator-boot-on;
 				};
 
-				dcdc3 {
+				tps65090_dcdc3_reg: dcdc3 {
 					regulator-name = "vdd-ao";
 					regulator-always-on;
 					regulator-boot-on;
@@ -836,6 +836,177 @@ 
 				};
 			};
 		};
+
+		palmas: tps65913@58 {
+			compatible = "ti,palmas";
+			reg = <0x58>;
+			interrupts = <0 86 0x4>;
+
+			#interrupt-cells = <2>;
+			interrupt-controller;
+
+			palmas_gpio: palmas_gpio {
+				compatible = "ti,palmas-gpio";
+				gpio-controller;
+				#gpio-cells = <2>;
+			};
+
+			palmas_rtc {
+				compatible = "ti,palmas-rtc";
+				interrupt-parent = <&palmas>;
+				interrupts = <8 0>;
+			};
+
+			palmas_pmic {
+			    compatible = "ti,tps65913-pmic", "ti,palmas-pmic";
+			    smps1-in-supply = <&tps65090_dcdc3_reg>;
+			    smps3-in-supply = <&tps65090_dcdc3_reg>;
+			    smps4-in-supply = <&tps65090_dcdc2_reg>;
+			    smps7-in-supply = <&tps65090_dcdc2_reg>;
+			    smps8-in-supply = <&tps65090_dcdc2_reg>;
+			    smps9-in-supply = <&tps65090_dcdc2_reg>;
+			    ldo1-in-supply = <&tps65090_dcdc2_reg>;
+			    ldo2-in-supply = <&tps65090_dcdc2_reg>;
+			    ldo3-in-supply = <&palmas_smps3_reg>;
+			    ldo4-in-supply = <&tps65090_dcdc2_reg>;
+			    ldo5-in-supply = <&vdd_ac_bat_reg>;
+			    ldo6-in-supply = <&tps65090_dcdc2_reg>;
+			    ldo7-in-supply = <&tps65090_dcdc2_reg>;
+			    ldo8-in-supply = <&tps65090_dcdc3_reg>;
+			    ldo9-in-supply = <&palmas_smps9_reg>;
+			    ldoln-in-supply = <&tps65090_dcdc1_reg>;
+			    ldousb-in-supply = <&tps65090_dcdc1_reg>;
+			    regulators {
+				smps12 {
+					regulator-name = "vddio-ddr";
+					regulator-min-microvolt = <1350000>;
+					regulator-max-microvolt = <1350000>;
+					regulator-always-on;
+					regulator-boot-on;
+				};
+
+				palmas_smps3_reg: smps3 {
+					regulator-name = "vddio-1v8";
+					regulator-min-microvolt = <1800000>;
+					regulator-max-microvolt = <1800000>;
+					regulator-always-on;
+					regulator-boot-on;
+				};
+
+				smps45 {
+					regulator-name = "vdd-core";
+					regulator-min-microvolt = <900000>;
+					regulator-max-microvolt = <1400000>;
+					regulator-always-on;
+					regulator-boot-on;
+				};
+
+				smps457 {
+					regulator-name = "vdd-core";
+					regulator-min-microvolt = <900000>;
+					regulator-max-microvolt = <1400000>;
+					regulator-always-on;
+					regulator-boot-on;
+				};
+
+				smps8 {
+					regulator-name = "avdd-pll";
+					regulator-min-microvolt = <1050000>;
+					regulator-max-microvolt = <1050000>;
+					regulator-always-on;
+					regulator-boot-on;
+				};
+
+				palmas_smps9_reg: smps9 {
+					regulator-name = "sdhci-vdd-sd-slot";
+					regulator-min-microvolt = <2800000>;
+					regulator-max-microvolt = <2800000>;
+					regulator-always-on;
+				};
+
+				ldo1 {
+					regulator-name = "avdd-cam1";
+					regulator-min-microvolt = <2800000>;
+					regulator-max-microvolt = <2800000>;
+				};
+
+				ldo2 {
+					regulator-name = "avdd-cam2";
+					regulator-min-microvolt = <2800000>;
+					regulator-max-microvolt = <2800000>;
+				};
+
+				ldo3 {
+					regulator-name = "avdd-dsi-csi";
+					regulator-min-microvolt = <1200000>;
+					regulator-max-microvolt = <1200000>;
+					regulator-always-on;
+					regulator-boot-on;
+				};
+
+				ldo4 {
+					regulator-name = "vpp-fuse";
+					regulator-min-microvolt = <1800000>;
+					regulator-max-microvolt = <1800000>;
+				};
+
+				ldo6 {
+					regulator-name = "vdd-sensor-2v85";
+					regulator-min-microvolt = <2850000>;
+					regulator-max-microvolt = <2850000>;
+				};
+
+				ldo7 {
+					regulator-name = "vdd-af-cam1";
+					regulator-min-microvolt = <2800000>;
+					regulator-max-microvolt = <2800000>;
+				};
+
+				ldo8 {
+					regulator-name = "vdd-rtc";
+					regulator-min-microvolt = <900000>;
+					regulator-max-microvolt = <900000>;
+					regulator-always-on;
+					regulator-boot-on;
+					ti,enable-ldo8-tracking;
+				};
+
+				ldo9 {
+					regulator-name = "vddio-sdmmc-2";
+					regulator-min-microvolt = <1800000>;
+					regulator-max-microvolt = <3300000>;
+				};
+
+				ldoln {
+					regulator-name = "hvdd-usb";
+					regulator-min-microvolt = <3300000>;
+					regulator-max-microvolt = <3300000>;
+				};
+
+				ldousb {
+					regulator-name = "avdd-usb";
+					regulator-min-microvolt = <3300000>;
+					regulator-max-microvolt = <3300000>;
+					regulator-always-on;
+					regulator-boot-on;
+				};
+
+				regen1 {
+					regulator-name = "rail-3v3";
+					regulator-max-microvolt = <3300000>;
+					regulator-always-on;
+					regulator-boot-on;
+				};
+
+				regen2 {
+					regulator-name = "rail-5v0";
+					regulator-max-microvolt = <5000000>;
+					regulator-always-on;
+					regulator-boot-on;
+				};
+			    };
+			};
+		};
 	};
 
 	spi@7000da00 {
@@ -951,6 +1122,16 @@ 
 			gpio = <&gpio TEGRA_GPIO(K, 1) GPIO_ACTIVE_HIGH>;
 			vin-supply = <&tps65090_dcdc1_reg>;
 		};
+
+		vdd_cam_1v8_reg: regulator@6 {
+			compatible = "regulator-fixed";
+			reg = <6>;
+			regulator-name = "vdd_cam_1v8_reg";
+			regulator-min-microvolt = <1800000>;
+			regulator-max-microvolt = <1800000>;
+			enable-active-high;
+			gpio = <&palmas_gpio 6 0>; /* Palmas GPIO6 */
+		};
 	};
 
 	sound {