aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/regulator
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2011-02-24 12:39:09 -0500
committerLiam Girdwood <lrg@slimlogic.co.uk>2011-03-26 10:15:03 -0400
commit23c2f041efa891e6ec0706dc9ad4f776a9aa8c14 (patch)
treeee6174b3a243c55bc4e00b7f6d49ac788abfec2d /drivers/regulator
parent16c29dafcc86024048f1dbb8349d31cb22c7c55a (diff)
regulator: If we fail when setting up a supply say which supply
Makes it a bit easier to identify if it's a problem with the supplies, the usual error would be omitting the supply name entirely. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Diffstat (limited to 'drivers/regulator')
-rw-r--r--drivers/regulator/core.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c
index 9fa20957847d..a2dc6223e8d2 100644
--- a/drivers/regulator/core.c
+++ b/drivers/regulator/core.c
@@ -2565,8 +2565,11 @@ struct regulator_dev *regulator_register(struct regulator_desc *regulator_desc,
2565 init_data->consumer_supplies[i].dev, 2565 init_data->consumer_supplies[i].dev,
2566 init_data->consumer_supplies[i].dev_name, 2566 init_data->consumer_supplies[i].dev_name,
2567 init_data->consumer_supplies[i].supply); 2567 init_data->consumer_supplies[i].supply);
2568 if (ret < 0) 2568 if (ret < 0) {
2569 dev_err(dev, "Failed to set supply %s\n",
2570 init_data->consumer_supplies[i].supply);
2569 goto unset_supplies; 2571 goto unset_supplies;
2572 }
2570 } 2573 }
2571 2574
2572 list_add(&rdev->list, &regulator_list); 2575 list_add(&rdev->list, &regulator_list);