Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions
max8925-regulator.c File Reference
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/init.h>
#include <linux/err.h>
#include <linux/i2c.h>
#include <linux/platform_device.h>
#include <linux/regulator/driver.h>
#include <linux/regulator/machine.h>
#include <linux/mfd/max8925.h>

Go to the source code of this file.

Data Structures

struct  max8925_regulator_info
 

Macros

#define SD1_DVM_VMIN   850000
 
#define SD1_DVM_VMAX   1000000
 
#define SD1_DVM_STEP   50000
 
#define SD1_DVM_SHIFT   5 /* SDCTL1 bit5 */
 
#define SD1_DVM_EN   6 /* SDV1 bit 6 */
 
#define LDO_SEQ_I2C   0x7 /* Power U/D by i2c */
 
#define LDO_SEQ_MASK   0x7 /* Power U/D sequence mask */
 
#define LDO_SEQ_SHIFT   2 /* Power U/D sequence offset */
 
#define LDO_I2C_EN   0x1 /* Enable by i2c */
 
#define LDO_I2C_EN_MASK   0x1 /* Enable mask by i2c */
 
#define LDO_I2C_EN_SHIFT   0 /* Enable offset by i2c */
 
#define MAX8925_SDV(_id, min, max, step)
 
#define MAX8925_LDO(_id, min, max, step)
 

Functions

 subsys_initcall (max8925_regulator_init)
 
 module_exit (max8925_regulator_exit)
 
 MODULE_LICENSE ("GPL")
 
 MODULE_AUTHOR ("Haojian Zhuang <[email protected]>")
 
 MODULE_DESCRIPTION ("Regulator Driver for Maxim 8925 PMIC")
 
 MODULE_ALIAS ("platform:max8925-regulator")
 

Macro Definition Documentation

#define LDO_I2C_EN   0x1 /* Enable by i2c */

Definition at line 31 of file max8925-regulator.c.

#define LDO_I2C_EN_MASK   0x1 /* Enable mask by i2c */

Definition at line 32 of file max8925-regulator.c.

#define LDO_I2C_EN_SHIFT   0 /* Enable offset by i2c */

Definition at line 33 of file max8925-regulator.c.

#define LDO_SEQ_I2C   0x7 /* Power U/D by i2c */

Definition at line 28 of file max8925-regulator.c.

#define LDO_SEQ_MASK   0x7 /* Power U/D sequence mask */

Definition at line 29 of file max8925-regulator.c.

#define LDO_SEQ_SHIFT   2 /* Power U/D sequence offset */

Definition at line 30 of file max8925-regulator.c.

#define MAX8925_LDO (   _id,
  min,
  max,
  step 
)
Value:
{ \
.desc = { \
.name = "LDO" #_id, \
.ops = &max8925_regulator_ldo_ops, \
.type = REGULATOR_VOLTAGE, \
.id = MAX8925_ID_LDO##_id, \
.owner = THIS_MODULE, \
.n_voltages = 64, \
.min_uV = min * 1000, \
.uV_step = step * 1000, \
}, \
.vol_reg = MAX8925_LDOVOUT##_id, \
.enable_reg = MAX8925_LDOCTL##_id, \
}

Definition at line 174 of file max8925-regulator.c.

#define MAX8925_SDV (   _id,
  min,
  max,
  step 
)
Value:
{ \
.desc = { \
.name = "SDV" #_id, \
.ops = &max8925_regulator_sdv_ops, \
.type = REGULATOR_VOLTAGE, \
.id = MAX8925_ID_SD##_id, \
.owner = THIS_MODULE, \
.n_voltages = 64, \
.min_uV = min * 1000, \
.uV_step = step * 1000, \
}, \
.vol_reg = MAX8925_SDV##_id, \
.enable_reg = MAX8925_SDCTL##_id, \
}

Definition at line 158 of file max8925-regulator.c.

#define SD1_DVM_EN   6 /* SDV1 bit 6 */

Definition at line 25 of file max8925-regulator.c.

#define SD1_DVM_SHIFT   5 /* SDCTL1 bit5 */

Definition at line 24 of file max8925-regulator.c.

#define SD1_DVM_STEP   50000

Definition at line 23 of file max8925-regulator.c.

#define SD1_DVM_VMAX   1000000

Definition at line 22 of file max8925-regulator.c.

#define SD1_DVM_VMIN   850000

Definition at line 21 of file max8925-regulator.c.

Function Documentation

MODULE_ALIAS ( "platform:max8925-regulator )
MODULE_AUTHOR ( "Haojian Zhuang <[email protected]>"  )
MODULE_DESCRIPTION ( "Regulator Driver for Maxim 8925 PMIC"  )
module_exit ( max8925_regulator_exit  )
MODULE_LICENSE ( "GPL"  )
subsys_initcall ( max8925_regulator_init  )