ARMV7: OMAP4: Add struct for twl603x data
[oweals/u-boot.git] / include / twl6030.h
index b4035ba4fe750d98b187afa77523ca48f9ba325c..9399737ad363e6a5d77fdf33b90946b779899185 100644 (file)
 #define GPCH0_LSB      0x57
 #define GPCH0_MSB      0x58
 
+#define TWL6030_VBAT_MULT      40 * 1000
+
+#define TWL6030_VBAT_SHIFT     (10 + 3)
+
+enum twl603x_chip_type{
+       chip_TWL6030,
+       chip_TWL603X_cnt
+};
+
+struct twl6030_data{
+       u8 chip_type;
+       u8 adc_rbase;
+       u8 adc_ctrl;
+       u8 adc_enable;
+       int vbat_mult;
+       int vbat_shift;
+};
+
 /* Functions to read and write from TWL6030 */
 static inline int twl6030_i2c_write_u8(u8 chip_no, u8 reg, u8 val)
 {