lkml.org 
[lkml]   [2013]   [Feb]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 36/49] regulator: ab8500: Don't register external regulators on AB8505
Date
From: Rabin Vincent <rabin.vincent@stericsson.com>

ExtSupply regulators are not included on AB8505 based platforms.

Signed-off-by: Rabin Vincent <rabin.vincent@stericsson.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Tested-by: Marcus COOPER <marcus.xm.cooper@stericsson.com>
---
drivers/regulator/ab8500.c | 20 ++++++++++++--------
1 file changed, 12 insertions(+), 8 deletions(-)

diff --git a/drivers/regulator/ab8500.c b/drivers/regulator/ab8500.c
index 1df809e..20c3270 100644
--- a/drivers/regulator/ab8500.c
+++ b/drivers/regulator/ab8500.c
@@ -2761,10 +2761,12 @@ static int ab8500_regulator_probe(struct platform_device *pdev)
return err;
}

- /* register external regulators (before Vaux1, 2 and 3) */
- err = ab8500_ext_regulator_init(pdev);
- if (err)
- return err;
+ if (!is_ab8505(ab8500)) {
+ /* register external regulators (before Vaux1, 2 and 3) */
+ err = ab8500_ext_regulator_init(pdev);
+ if (err)
+ return err;
+ }

/* register all regulators */
for (i = 0; i < regulator_info_size; i++) {
@@ -2806,10 +2808,12 @@ static int ab8500_regulator_remove(struct platform_device *pdev)
regulator_unregister(info->regulator);
}

- /* remove external regulators (after Vaux1, 2 and 3) */
- err = ab8500_ext_regulator_exit(pdev);
- if (err)
- return err;
+ if (!is_ab8505(ab8500)) {
+ /* remove external regulators (after Vaux1, 2 and 3) */
+ err = ab8500_ext_regulator_exit(pdev);
+ if (err)
+ return err;
+ }

/* remove regulator debug */
err = ab8500_regulator_debug_exit(pdev);
--
1.7.9.5


\
 
 \ /
  Last update: 2013-02-06 13:21    [W:0.224 / U:0.292 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site