aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLaxman Dewangan <ldewangan@nvidia.com>2012-05-20 12:18:49 -0400
committerMark Brown <broonie@opensource.wolfsonmicro.com>2012-05-20 13:22:41 -0400
commit92ab953bd6477b816e8ddd2cf9eaed063332013a (patch)
tree78ed8f8966bbd155d4c4bcc903a54f22cf67fdcd
parent7e9a57e6267591ddfdd3beaf26f21b5257c5fff8 (diff)
regulator: tps65910: dt: support when "regulators" node found
The device tree binding for the tps65910 is described as: tps65911 { reg = <0x2d> ::::::::: regulators { compatible = "ti,tps65911"; ldo1_reg: ldo1 { /** regulator entry */ }; ldo2_reg: ldo2 { /** regulator entry */ }; :::::::::: }; }; Support the regulators functionality only when there is "regulators" child node available for tps65910. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
-rw-r--r--drivers/regulator/tps65910-regulator.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/regulator/tps65910-regulator.c b/drivers/regulator/tps65910-regulator.c
index 11af48e7186a..8b31f073c6f3 100644
--- a/drivers/regulator/tps65910-regulator.c
+++ b/drivers/regulator/tps65910-regulator.c
@@ -1090,6 +1090,10 @@ static struct tps65910_board *tps65910_parse_dt_reg_data(
1090 } 1090 }
1091 1091
1092 regulators = of_find_node_by_name(np, "regulators"); 1092 regulators = of_find_node_by_name(np, "regulators");
1093 if (!regulators) {
1094 dev_err(&pdev->dev, "regulator node not found\n");
1095 return NULL;
1096 }
1093 1097
1094 switch (tps65910_chip_id(tps65910)) { 1098 switch (tps65910_chip_id(tps65910)) {
1095 case TPS65910: 1099 case TPS65910: