diff options
Diffstat (limited to 'include/linux/i2c/twl.h')
-rw-r--r-- | include/linux/i2c/twl.h | 73 |
1 files changed, 36 insertions, 37 deletions
diff --git a/include/linux/i2c/twl.h b/include/linux/i2c/twl.h index 9a5e28462324..1ff54b114efc 100644 --- a/include/linux/i2c/twl.h +++ b/include/linux/i2c/twl.h | |||
@@ -39,52 +39,51 @@ | |||
39 | * address each module uses within a given i2c slave. | 39 | * address each module uses within a given i2c slave. |
40 | */ | 40 | */ |
41 | 41 | ||
42 | /* Slave 0 (i2c address 0x48) */ | 42 | enum twl4030_module_ids { |
43 | #define TWL4030_MODULE_USB 0x00 | 43 | TWL4030_MODULE_USB = 0, /* Slave 0 (i2c address 0x48) */ |
44 | 44 | TWL4030_MODULE_AUDIO_VOICE, /* Slave 1 (i2c address 0x49) */ | |
45 | /* Slave 1 (i2c address 0x49) */ | 45 | TWL4030_MODULE_GPIO, |
46 | #define TWL4030_MODULE_AUDIO_VOICE 0x01 | 46 | TWL4030_MODULE_INTBR, |
47 | #define TWL4030_MODULE_GPIO 0x02 | 47 | TWL4030_MODULE_PIH, |
48 | #define TWL4030_MODULE_INTBR 0x03 | 48 | |
49 | #define TWL4030_MODULE_PIH 0x04 | 49 | TWL4030_MODULE_TEST, |
50 | #define TWL4030_MODULE_TEST 0x05 | 50 | TWL4030_MODULE_KEYPAD, /* Slave 2 (i2c address 0x4a) */ |
51 | 51 | TWL4030_MODULE_MADC, | |
52 | /* Slave 2 (i2c address 0x4a) */ | 52 | TWL4030_MODULE_INTERRUPTS, |
53 | #define TWL4030_MODULE_KEYPAD 0x06 | 53 | TWL4030_MODULE_LED, |
54 | #define TWL4030_MODULE_MADC 0x07 | 54 | |
55 | #define TWL4030_MODULE_INTERRUPTS 0x08 | 55 | TWL4030_MODULE_MAIN_CHARGE, |
56 | #define TWL4030_MODULE_LED 0x09 | 56 | TWL4030_MODULE_PRECHARGE, |
57 | #define TWL4030_MODULE_MAIN_CHARGE 0x0A | 57 | TWL4030_MODULE_PWM0, |
58 | #define TWL4030_MODULE_PRECHARGE 0x0B | 58 | TWL4030_MODULE_PWM1, |
59 | #define TWL4030_MODULE_PWM0 0x0C | 59 | TWL4030_MODULE_PWMA, |
60 | #define TWL4030_MODULE_PWM1 0x0D | 60 | |
61 | #define TWL4030_MODULE_PWMA 0x0E | 61 | TWL4030_MODULE_PWMB, |
62 | #define TWL4030_MODULE_PWMB 0x0F | 62 | TWL5031_MODULE_ACCESSORY, |
63 | 63 | TWL5031_MODULE_INTERRUPTS, | |
64 | #define TWL5031_MODULE_ACCESSORY 0x10 | 64 | TWL4030_MODULE_BACKUP, /* Slave 3 (i2c address 0x4b) */ |
65 | #define TWL5031_MODULE_INTERRUPTS 0x11 | 65 | TWL4030_MODULE_INT, |
66 | 66 | ||
67 | /* Slave 3 (i2c address 0x4b) */ | 67 | TWL4030_MODULE_PM_MASTER, |
68 | #define TWL4030_MODULE_BACKUP 0x12 | 68 | TWL4030_MODULE_PM_RECEIVER, |
69 | #define TWL4030_MODULE_INT 0x13 | 69 | TWL4030_MODULE_RTC, |
70 | #define TWL4030_MODULE_PM_MASTER 0x14 | 70 | TWL4030_MODULE_SECURED_REG, |
71 | #define TWL4030_MODULE_PM_RECEIVER 0x15 | 71 | TWL4030_MODULE_LAST, |
72 | #define TWL4030_MODULE_RTC 0x16 | 72 | }; |
73 | #define TWL4030_MODULE_SECURED_REG 0x17 | ||
74 | 73 | ||
74 | /* Similar functionalities implemented in TWL4030/6030 */ | ||
75 | #define TWL_MODULE_USB TWL4030_MODULE_USB | 75 | #define TWL_MODULE_USB TWL4030_MODULE_USB |
76 | #define TWL_MODULE_AUDIO_VOICE TWL4030_MODULE_AUDIO_VOICE | ||
77 | #define TWL_MODULE_PIH TWL4030_MODULE_PIH | 76 | #define TWL_MODULE_PIH TWL4030_MODULE_PIH |
78 | #define TWL_MODULE_MADC TWL4030_MODULE_MADC | ||
79 | #define TWL_MODULE_MAIN_CHARGE TWL4030_MODULE_MAIN_CHARGE | 77 | #define TWL_MODULE_MAIN_CHARGE TWL4030_MODULE_MAIN_CHARGE |
80 | #define TWL_MODULE_PM_MASTER TWL4030_MODULE_PM_MASTER | 78 | #define TWL_MODULE_PM_MASTER TWL4030_MODULE_PM_MASTER |
81 | #define TWL_MODULE_PM_RECEIVER TWL4030_MODULE_PM_RECEIVER | 79 | #define TWL_MODULE_PM_RECEIVER TWL4030_MODULE_PM_RECEIVER |
82 | #define TWL_MODULE_RTC TWL4030_MODULE_RTC | 80 | #define TWL_MODULE_RTC TWL4030_MODULE_RTC |
83 | #define TWL_MODULE_PWM TWL4030_MODULE_PWM0 | 81 | #define TWL_MODULE_PWM TWL4030_MODULE_PWM0 |
82 | #define TWL_MODULE_LED TWL4030_MODULE_LED | ||
84 | 83 | ||
85 | #define TWL6030_MODULE_ID0 0x0D | 84 | #define TWL6030_MODULE_ID0 13 |
86 | #define TWL6030_MODULE_ID1 0x0E | 85 | #define TWL6030_MODULE_ID1 14 |
87 | #define TWL6030_MODULE_ID2 0x0F | 86 | #define TWL6030_MODULE_ID2 15 |
88 | 87 | ||
89 | #define GPIO_INTR_OFFSET 0 | 88 | #define GPIO_INTR_OFFSET 0 |
90 | #define KEYPAD_INTR_OFFSET 1 | 89 | #define KEYPAD_INTR_OFFSET 1 |