diff options
Diffstat (limited to 'drivers/regulator/max8952.c')
-rw-r--r-- | drivers/regulator/max8952.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/regulator/max8952.c b/drivers/regulator/max8952.c index 0d5dda4fd91..a8f4ecfb084 100644 --- a/drivers/regulator/max8952.c +++ b/drivers/regulator/max8952.c | |||
@@ -133,7 +133,7 @@ static int max8952_get_voltage(struct regulator_dev *rdev) | |||
133 | } | 133 | } |
134 | 134 | ||
135 | static int max8952_set_voltage(struct regulator_dev *rdev, | 135 | static int max8952_set_voltage(struct regulator_dev *rdev, |
136 | int min_uV, int max_uV) | 136 | int min_uV, int max_uV, unsigned *selector) |
137 | { | 137 | { |
138 | struct max8952_data *max8952 = rdev_get_drvdata(rdev); | 138 | struct max8952_data *max8952 = rdev_get_drvdata(rdev); |
139 | s8 vid = -1, i; | 139 | s8 vid = -1, i; |
@@ -156,6 +156,7 @@ static int max8952_set_voltage(struct regulator_dev *rdev, | |||
156 | if (vid >= 0 && vid < MAX8952_NUM_DVS_MODE) { | 156 | if (vid >= 0 && vid < MAX8952_NUM_DVS_MODE) { |
157 | max8952->vid0 = (vid % 2 == 1); | 157 | max8952->vid0 = (vid % 2 == 1); |
158 | max8952->vid1 = (((vid >> 1) % 2) == 1); | 158 | max8952->vid1 = (((vid >> 1) % 2) == 1); |
159 | *selector = vid; | ||
159 | gpio_set_value(max8952->pdata->gpio_vid0, max8952->vid0); | 160 | gpio_set_value(max8952->pdata->gpio_vid0, max8952->vid0); |
160 | gpio_set_value(max8952->pdata->gpio_vid1, max8952->vid1); | 161 | gpio_set_value(max8952->pdata->gpio_vid1, max8952->vid1); |
161 | } else | 162 | } else |