diff options
| author | Axel Lin <axel.lin@ingics.com> | 2012-12-17 20:30:10 -0500 |
|---|---|---|
| committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-12-24 11:34:11 -0500 |
| commit | c8520b4c5d25eb7b8b54f1ae9ba7da71375f2b2c (patch) | |
| tree | 30ac7c7e9f1f2a00523019409bf223a5a4417aa9 /include/linux/regulator | |
| parent | a49f0d1ea3ec94fc7cf33a7c36a16343b74bd565 (diff) | |
regulator: core: Allow specify apply_[reg|bit] for regmap based voltage_sel operations
Some DVM regulators needs to update apply_bit after setting vsel_reg to
initiate voltage change on the output. This patch adds apply_reg and
apply_bit to struct regulator_desc and update
regulator_set_voltage_sel_regmap() to set apply_bit of apply_reg when
apply_bit is set.
Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'include/linux/regulator')
| -rw-r--r-- | include/linux/regulator/driver.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/regulator/driver.h b/include/linux/regulator/driver.h index d10bb0f39c5e..23070fd83872 100644 --- a/include/linux/regulator/driver.h +++ b/include/linux/regulator/driver.h | |||
| @@ -193,6 +193,10 @@ enum regulator_type { | |||
| 193 | * | 193 | * |
| 194 | * @vsel_reg: Register for selector when using regulator_regmap_X_voltage_ | 194 | * @vsel_reg: Register for selector when using regulator_regmap_X_voltage_ |
| 195 | * @vsel_mask: Mask for register bitfield used for selector | 195 | * @vsel_mask: Mask for register bitfield used for selector |
| 196 | * @apply_reg: Register for initiate voltage change on the output when | ||
| 197 | * using regulator_set_voltage_sel_regmap | ||
| 198 | * @apply_bit: Register bitfield used for initiate voltage change on the | ||
| 199 | * output when using regulator_set_voltage_sel_regmap | ||
| 196 | * @enable_reg: Register for control when using regmap enable/disable ops | 200 | * @enable_reg: Register for control when using regmap enable/disable ops |
| 197 | * @enable_mask: Mask for control when using regmap enable/disable ops | 201 | * @enable_mask: Mask for control when using regmap enable/disable ops |
| 198 | * | 202 | * |
| @@ -218,6 +222,8 @@ struct regulator_desc { | |||
| 218 | 222 | ||
| 219 | unsigned int vsel_reg; | 223 | unsigned int vsel_reg; |
| 220 | unsigned int vsel_mask; | 224 | unsigned int vsel_mask; |
| 225 | unsigned int apply_reg; | ||
| 226 | unsigned int apply_bit; | ||
| 221 | unsigned int enable_reg; | 227 | unsigned int enable_reg; |
| 222 | unsigned int enable_mask; | 228 | unsigned int enable_mask; |
| 223 | unsigned int bypass_reg; | 229 | unsigned int bypass_reg; |
