aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorLaxman Dewangan <ldewangan@nvidia.com>2012-04-04 03:14:00 -0400
committerMark Brown <broonie@opensource.wolfsonmicro.com>2012-04-04 06:48:02 -0400
commit6ffc3270210efa2bea526953a142ffc908f5bd86 (patch)
treee05119524423cebeceb0f263901752decfed6fe5 /include/linux
parent173f24d1ffe23f46b689159ee9d6b6aa402ff2e9 (diff)
regulator: Add support for RICOH PMIC RC5T583 regulator
The RC5T583 PMIC from RICOH consists of 4 DCDC and 10 LDOs. This driver supports the control of different regulator output through regulator interface. This driver depends on MFD driver of RC5T583 and uses mfd rc5t583 apis to communicate to device for accessing different device's registers. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/mfd/rc5t583.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/include/linux/mfd/rc5t583.h b/include/linux/mfd/rc5t583.h
index a2c61609d21d..b2c1f442d4ef 100644
--- a/include/linux/mfd/rc5t583.h
+++ b/include/linux/mfd/rc5t583.h
@@ -249,6 +249,26 @@ enum {
249 RC5T583_EXT_PWRREQ2_CONTROL = 0x2, 249 RC5T583_EXT_PWRREQ2_CONTROL = 0x2,
250}; 250};
251 251
252enum {
253 RC5T583_REGULATOR_DC0,
254 RC5T583_REGULATOR_DC1,
255 RC5T583_REGULATOR_DC2,
256 RC5T583_REGULATOR_DC3,
257 RC5T583_REGULATOR_LDO0,
258 RC5T583_REGULATOR_LDO1,
259 RC5T583_REGULATOR_LDO2,
260 RC5T583_REGULATOR_LDO3,
261 RC5T583_REGULATOR_LDO4,
262 RC5T583_REGULATOR_LDO5,
263 RC5T583_REGULATOR_LDO6,
264 RC5T583_REGULATOR_LDO7,
265 RC5T583_REGULATOR_LDO8,
266 RC5T583_REGULATOR_LDO9,
267
268 /* Should be last entry */
269 RC5T583_REGULATOR_MAX,
270};
271
252struct rc5t583 { 272struct rc5t583 {
253 struct device *dev; 273 struct device *dev;
254 struct regmap *regmap; 274 struct regmap *regmap;
@@ -272,11 +292,20 @@ struct rc5t583 {
272 * The board specific data is provided through this structure. 292 * The board specific data is provided through this structure.
273 * @irq_base: Irq base number on which this device registers their interrupts. 293 * @irq_base: Irq base number on which this device registers their interrupts.
274 * @enable_shutdown: Enable shutdown through the input pin "shutdown". 294 * @enable_shutdown: Enable shutdown through the input pin "shutdown".
295 * @regulator_deepsleep_slot: The slot number on which device goes to sleep
296 * in device sleep mode.
297 * @regulator_ext_pwr_control: External power request regulator control. The
298 * regulator output enable/disable is controlled by the external
299 * power request input state.
300 * @reg_init_data: Regulator init data.
275 */ 301 */
276 302
277struct rc5t583_platform_data { 303struct rc5t583_platform_data {
278 int irq_base; 304 int irq_base;
279 bool enable_shutdown; 305 bool enable_shutdown;
306 int regulator_deepsleep_slot[RC5T583_REGULATOR_MAX];
307 unsigned long regulator_ext_pwr_control[RC5T583_REGULATOR_MAX];
308 struct regulator_init_data *reg_init_data[RC5T583_REGULATOR_MAX];
280}; 309};
281 310
282int rc5t583_write(struct device *dev, u8 reg, uint8_t val); 311int rc5t583_write(struct device *dev, u8 reg, uint8_t val);