diff options
author | Axel Lin <axel.lin@ingics.com> | 2013-04-07 17:15:24 +0200 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2013-04-08 12:23:49 +0200 |
commit | bcbba9de0f66d30621a489dc8af07350f8d477fd (patch) | |
tree | 6182b3dddbb3b97883e55e88f49ba4e6f5d17c32 /drivers/regulator/ab8500-ext.c | |
parent | regulator: ab8500-ext: Get rid of is_enabled from struct ab8500_ext_regulator... (diff) | |
download | linux-bcbba9de0f66d30621a489dc8af07350f8d477fd.tar.xz linux-bcbba9de0f66d30621a489dc8af07350f8d477fd.zip |
regulator: ab8500-ext: Remove unnecessary checking for ab9540 and ab8540
This code was added by commit 0fe17e20a6
"regulator: ab8500-ext: Add support for AB9540 regulators"
and commit bd44e2cb "regulator: ab8500: Also check for AB8505 based platforms"
The original patch[1] is to set info->desc.ops = &ab9540_ext_regulator_ops.
However, ab9540_ext_regulator_ops is identical to ab8500_ext_regulator_ops[2].
Thus we can complete remove the unnecessary checking for ab9540 and ab8540.
[1] https://lkml.org/lkml/2013/3/28/333
[2] https://lkml.org/lkml/2013/4/1/178
Signed-off-by: Axel Lin <axel.lin@ingics.com>
Acked-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'drivers/regulator/ab8500-ext.c')
-rw-r--r-- | drivers/regulator/ab8500-ext.c | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/drivers/regulator/ab8500-ext.c b/drivers/regulator/ab8500-ext.c index 5e604a2ad7cd..c7896af4aaa8 100644 --- a/drivers/regulator/ab8500-ext.c +++ b/drivers/regulator/ab8500-ext.c @@ -389,15 +389,8 @@ int ab8500_ext_regulator_init(struct platform_device *pdev) config.init_data = &pdata->ext_regulator[i]; config.driver_data = info; - if ((is_ab9540(ab8500) || is_ab8540(ab8500)) && - ((info->desc.id == AB8500_EXT_SUPPLY1) || - (info->desc.id == AB8500_EXT_SUPPLY2) || - (info->desc.id == AB8500_EXT_SUPPLY3))) - info->desc.ops = &ab8500_ext_regulator_ops; - /* register regulator with framework */ info->rdev = regulator_register(&info->desc, &config); - if (IS_ERR(info->rdev)) { err = PTR_ERR(info->rdev); dev_err(&pdev->dev, "failed to register regulator %s\n", |