diff options
author | Krzysztof Kozlowski <k.kozlowski@samsung.com> | 2014-05-06 02:37:38 -0400 |
---|---|---|
committer | Mark Brown <broonie@linaro.org> | 2014-05-17 09:30:06 -0400 |
commit | 0608032a9067c165e5ed75c56311a08cbb28564f (patch) | |
tree | 6755b4477dce4eb85b1227b32adfae656047986f | |
parent | 51e2fc0a251ba64c68207e4c6f6ac33c891b2465 (diff) |
regulator: s2mpa01: Use rdev_get_id() to access id of regulator
Use regulator API rdev_get_id() to access id of regulator.
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Reviewed-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
-rw-r--r-- | drivers/regulator/s2mpa01.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/regulator/s2mpa01.c b/drivers/regulator/s2mpa01.c index cab1a2b9efc5..b71e11a6c773 100644 --- a/drivers/regulator/s2mpa01.c +++ b/drivers/regulator/s2mpa01.c | |||
@@ -61,7 +61,7 @@ static int s2mpa01_regulator_set_voltage_time_sel(struct regulator_dev *rdev, | |||
61 | unsigned int ramp_delay = 0; | 61 | unsigned int ramp_delay = 0; |
62 | int old_volt, new_volt; | 62 | int old_volt, new_volt; |
63 | 63 | ||
64 | switch (rdev->desc->id) { | 64 | switch (rdev_get_id(rdev)) { |
65 | case S2MPA01_BUCK2: | 65 | case S2MPA01_BUCK2: |
66 | case S2MPA01_BUCK4: | 66 | case S2MPA01_BUCK4: |
67 | ramp_delay = s2mpa01->ramp_delay24; | 67 | ramp_delay = s2mpa01->ramp_delay24; |
@@ -102,7 +102,7 @@ static int s2mpa01_set_ramp_delay(struct regulator_dev *rdev, int ramp_delay) | |||
102 | unsigned int ramp_enable = 1, enable_shift = 0; | 102 | unsigned int ramp_enable = 1, enable_shift = 0; |
103 | int ret; | 103 | int ret; |
104 | 104 | ||
105 | switch (rdev->desc->id) { | 105 | switch (rdev_get_id(rdev)) { |
106 | case S2MPA01_BUCK1: | 106 | case S2MPA01_BUCK1: |
107 | enable_shift = S2MPA01_BUCK1_RAMP_EN_SHIFT; | 107 | enable_shift = S2MPA01_BUCK1_RAMP_EN_SHIFT; |
108 | if (!ramp_delay) { | 108 | if (!ramp_delay) { |