summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/regulator/bcm590xx-regulator.c1
-rw-r--r--drivers/regulator/s2mpa01.c12
-rw-r--r--drivers/regulator/s2mps11.c12
-rw-r--r--drivers/regulator/s5m8767.c1
4 files changed, 12 insertions, 14 deletions
diff --git a/drivers/regulator/bcm590xx-regulator.c b/drivers/regulator/bcm590xx-regulator.c
index ab08ca7cfb08..c3750c5b382b 100644
--- a/drivers/regulator/bcm590xx-regulator.c
+++ b/drivers/regulator/bcm590xx-regulator.c
@@ -123,6 +123,7 @@ struct bcm590xx_info {
123#define BCM590XX_REG_RANGES(_name, _ranges) \ 123#define BCM590XX_REG_RANGES(_name, _ranges) \
124 { \ 124 { \
125 .name = #_name, \ 125 .name = #_name, \
126 .n_voltages = 64, \
126 .n_linear_ranges = ARRAY_SIZE(_ranges), \ 127 .n_linear_ranges = ARRAY_SIZE(_ranges), \
127 .linear_ranges = _ranges, \ 128 .linear_ranges = _ranges, \
128 } 129 }
diff --git a/drivers/regulator/s2mpa01.c b/drivers/regulator/s2mpa01.c
index 808b3aa7a42c..f19a30f0fb42 100644
--- a/drivers/regulator/s2mpa01.c
+++ b/drivers/regulator/s2mpa01.c
@@ -192,13 +192,11 @@ static int s2mpa01_set_ramp_delay(struct regulator_dev *rdev, int ramp_delay)
192 if (!ramp_enable) 192 if (!ramp_enable)
193 goto ramp_disable; 193 goto ramp_disable;
194 194
195 if (enable_shift) { 195 ret = regmap_update_bits(rdev->regmap, S2MPA01_REG_RAMP1,
196 ret = regmap_update_bits(rdev->regmap, S2MPA01_REG_RAMP1, 196 1 << enable_shift, 1 << enable_shift);
197 1 << enable_shift, 1 << enable_shift); 197 if (ret) {
198 if (ret) { 198 dev_err(&rdev->dev, "failed to enable ramp rate\n");
199 dev_err(&rdev->dev, "failed to enable ramp rate\n"); 199 return ret;
200 return ret;
201 }
202 } 200 }
203 201
204 ramp_val = get_ramp_delay(ramp_delay); 202 ramp_val = get_ramp_delay(ramp_delay);
diff --git a/drivers/regulator/s2mps11.c b/drivers/regulator/s2mps11.c
index 68fd54702edb..e713c162fbd4 100644
--- a/drivers/regulator/s2mps11.c
+++ b/drivers/regulator/s2mps11.c
@@ -202,13 +202,11 @@ static int s2mps11_set_ramp_delay(struct regulator_dev *rdev, int ramp_delay)
202 if (!ramp_enable) 202 if (!ramp_enable)
203 goto ramp_disable; 203 goto ramp_disable;
204 204
205 if (enable_shift) { 205 ret = regmap_update_bits(rdev->regmap, S2MPS11_REG_RAMP,
206 ret = regmap_update_bits(rdev->regmap, S2MPS11_REG_RAMP, 206 1 << enable_shift, 1 << enable_shift);
207 1 << enable_shift, 1 << enable_shift); 207 if (ret) {
208 if (ret) { 208 dev_err(&rdev->dev, "failed to enable ramp rate\n");
209 dev_err(&rdev->dev, "failed to enable ramp rate\n"); 209 return ret;
210 return ret;
211 }
212 } 210 }
213 211
214 ramp_val = get_ramp_delay(ramp_delay); 212 ramp_val = get_ramp_delay(ramp_delay);
diff --git a/drivers/regulator/s5m8767.c b/drivers/regulator/s5m8767.c
index f05badabd69e..92f19a005dc3 100644
--- a/drivers/regulator/s5m8767.c
+++ b/drivers/regulator/s5m8767.c
@@ -964,6 +964,7 @@ static int s5m8767_pmic_probe(struct platform_device *pdev)
964 config.driver_data = s5m8767; 964 config.driver_data = s5m8767;
965 config.regmap = iodev->regmap_pmic; 965 config.regmap = iodev->regmap_pmic;
966 config.of_node = pdata->regulators[i].reg_node; 966 config.of_node = pdata->regulators[i].reg_node;
967 config.ena_gpio = config.ena_gpio_flags = 0;
967 if (pdata->regulators[i].ext_control_gpio) 968 if (pdata->regulators[i].ext_control_gpio)
968 s5m8767_regulator_config_ext_control(s5m8767, 969 s5m8767_regulator_config_ext_control(s5m8767,
969 &pdata->regulators[i], &config); 970 &pdata->regulators[i], &config);