blob: 8b729b0ff3356b0d917d650a0eab777c653bce15 [file] [log] [blame]
Nick Pellyb3765b22010-08-16 15:31:01 -07001/****************************************************************************
2 ****************************************************************************
3 ***
4 *** This header was automatically generated from a Linux kernel header
5 *** of the same name, to make information necessary for userspace to
6 *** call into the kernel available to libc. It contains only constants,
7 *** structures, and macros generated from the original header, and thus,
8 *** contains no copyrightable information.
9 ***
Ben Cheng654325d2012-03-07 21:13:49 -080010 *** To edit the content of this header, modify the corresponding
11 *** source file (e.g. under external/kernel-headers/original/) then
12 *** run bionic/libc/kernel/tools/update_all.py
13 ***
14 *** Any manual change here will be lost the next time this script will
15 *** be run. You've been warned!
16 ***
Nick Pellyb3765b22010-08-16 15:31:01 -070017 ****************************************************************************
18 ****************************************************************************/
19#ifndef _LINUX_SPI_CPCAP_H
20#define _LINUX_SPI_CPCAP_H
Nick Pellyb3765b22010-08-16 15:31:01 -070021#include <linux/ioctl.h>
Nick Pellyb3765b22010-08-16 15:31:01 -070022#define CPCAP_DEV_NAME "cpcap"
Ben Cheng654325d2012-03-07 21:13:49 -080023/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -070024#define CPCAP_NUM_REG_CPCAP (CPCAP_REG_END - CPCAP_REG_START + 1)
Nick Pellyb3765b22010-08-16 15:31:01 -070025#define CPCAP_IRQ_INT1_INDEX 0
26#define CPCAP_IRQ_INT2_INDEX 16
27#define CPCAP_IRQ_INT3_INDEX 32
Ben Cheng654325d2012-03-07 21:13:49 -080028/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -070029#define CPCAP_IRQ_INT4_INDEX 48
30#define CPCAP_IRQ_INT5_INDEX 64
Iliyan Malchevbb3bcbc2010-11-02 15:58:36 -070031#define CPCAP_HWCFG_NUM 2
Iliyan Malchevbb3bcbc2010-11-02 15:58:36 -070032#define CPCAP_HWCFG0_SEC_STBY_SW1 0x0001
Ben Cheng654325d2012-03-07 21:13:49 -080033/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Iliyan Malchevbb3bcbc2010-11-02 15:58:36 -070034#define CPCAP_HWCFG0_SEC_STBY_SW2 0x0002
35#define CPCAP_HWCFG0_SEC_STBY_SW3 0x0004
36#define CPCAP_HWCFG0_SEC_STBY_SW4 0x0008
37#define CPCAP_HWCFG0_SEC_STBY_SW5 0x0010
Ben Cheng654325d2012-03-07 21:13:49 -080038/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Iliyan Malchevbb3bcbc2010-11-02 15:58:36 -070039#define CPCAP_HWCFG0_SEC_STBY_VAUDIO 0x0020
40#define CPCAP_HWCFG0_SEC_STBY_VCAM 0x0040
41#define CPCAP_HWCFG0_SEC_STBY_VCSI 0x0080
42#define CPCAP_HWCFG0_SEC_STBY_VDAC 0x0100
Ben Cheng654325d2012-03-07 21:13:49 -080043/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Iliyan Malchevbb3bcbc2010-11-02 15:58:36 -070044#define CPCAP_HWCFG0_SEC_STBY_VDIG 0x0200
45#define CPCAP_HWCFG0_SEC_STBY_VHVIO 0x0400
46#define CPCAP_HWCFG0_SEC_STBY_VPLL 0x0800
47#define CPCAP_HWCFG0_SEC_STBY_VRF1 0x1000
Ben Cheng654325d2012-03-07 21:13:49 -080048/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Iliyan Malchevbb3bcbc2010-11-02 15:58:36 -070049#define CPCAP_HWCFG0_SEC_STBY_VRF2 0x2000
50#define CPCAP_HWCFG0_SEC_STBY_VRFREF 0x4000
51#define CPCAP_HWCFG0_SEC_STBY_VSDIO 0x8000
Iliyan Malchevbb3bcbc2010-11-02 15:58:36 -070052#define CPCAP_HWCFG1_SEC_STBY_VWLAN1 0x0001
Ben Cheng654325d2012-03-07 21:13:49 -080053/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Iliyan Malchevbb3bcbc2010-11-02 15:58:36 -070054#define CPCAP_HWCFG1_SEC_STBY_VWLAN2 0x0002
55#define CPCAP_HWCFG1_SEC_STBY_VSIM 0x0004
56#define CPCAP_HWCFG1_SEC_STBY_VSIMCARD 0x0008
Nick Pellyb3765b22010-08-16 15:31:01 -070057#define CPCAP_WHISPER_MODE_PU 0x00000001
Ben Cheng654325d2012-03-07 21:13:49 -080058/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -070059#define CPCAP_WHISPER_ENABLE_UART 0x00000002
60#define CPCAP_WHISPER_ACCY_MASK 0xF8000000
61#define CPCAP_WHISPER_ACCY_SHFT 27
62#define CPCAP_WHISPER_ID_SIZE 16
Ben Cheng654325d2012-03-07 21:13:49 -080063/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Iliyan Malchevbb3bcbc2010-11-02 15:58:36 -070064#define CPCAP_WHISPER_PROP_SIZE 7
Nick Pellyb3765b22010-08-16 15:31:01 -070065enum cpcap_regulator_id {
66 CPCAP_SW2,
67 CPCAP_SW4,
Ben Cheng654325d2012-03-07 21:13:49 -080068/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -070069 CPCAP_SW5,
70 CPCAP_VCAM,
71 CPCAP_VCSI,
72 CPCAP_VDAC,
Ben Cheng654325d2012-03-07 21:13:49 -080073/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -070074 CPCAP_VDIG,
75 CPCAP_VFUSE,
76 CPCAP_VHVIO,
77 CPCAP_VSDIO,
Ben Cheng654325d2012-03-07 21:13:49 -080078/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -070079 CPCAP_VPLL,
80 CPCAP_VRF1,
81 CPCAP_VRF2,
82 CPCAP_VRFREF,
Ben Cheng654325d2012-03-07 21:13:49 -080083/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -070084 CPCAP_VWLAN1,
85 CPCAP_VWLAN2,
86 CPCAP_VSIM,
87 CPCAP_VSIMCARD,
Ben Cheng654325d2012-03-07 21:13:49 -080088/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -070089 CPCAP_VVIB,
90 CPCAP_VUSB,
91 CPCAP_VAUDIO,
92 CPCAP_NUM_REGULATORS
Ben Cheng654325d2012-03-07 21:13:49 -080093/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -070094};
Nick Pellyb3765b22010-08-16 15:31:01 -070095enum cpcap_reg {
96 CPCAP_REG_START,
Nick Pellyb3765b22010-08-16 15:31:01 -070097 CPCAP_REG_INT1 = CPCAP_REG_START,
Ben Cheng654325d2012-03-07 21:13:49 -080098/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -070099 CPCAP_REG_INT2,
100 CPCAP_REG_INT3,
101 CPCAP_REG_INT4,
102 CPCAP_REG_INTM1,
Ben Cheng654325d2012-03-07 21:13:49 -0800103/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700104 CPCAP_REG_INTM2,
105 CPCAP_REG_INTM3,
106 CPCAP_REG_INTM4,
107 CPCAP_REG_INTS1,
Ben Cheng654325d2012-03-07 21:13:49 -0800108/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700109 CPCAP_REG_INTS2,
110 CPCAP_REG_INTS3,
111 CPCAP_REG_INTS4,
112 CPCAP_REG_ASSIGN1,
Ben Cheng654325d2012-03-07 21:13:49 -0800113/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700114 CPCAP_REG_ASSIGN2,
115 CPCAP_REG_ASSIGN3,
116 CPCAP_REG_ASSIGN4,
117 CPCAP_REG_ASSIGN5,
Ben Cheng654325d2012-03-07 21:13:49 -0800118/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700119 CPCAP_REG_ASSIGN6,
120 CPCAP_REG_VERSC1,
121 CPCAP_REG_VERSC2,
Nick Pellyb3765b22010-08-16 15:31:01 -0700122 CPCAP_REG_MI1,
Ben Cheng654325d2012-03-07 21:13:49 -0800123/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700124 CPCAP_REG_MIM1,
125 CPCAP_REG_MI2,
126 CPCAP_REG_MIM2,
127 CPCAP_REG_UCC1,
Ben Cheng654325d2012-03-07 21:13:49 -0800128/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700129 CPCAP_REG_UCC2,
130 CPCAP_REG_PC1,
131 CPCAP_REG_PC2,
132 CPCAP_REG_BPEOL,
Ben Cheng654325d2012-03-07 21:13:49 -0800133/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700134 CPCAP_REG_PGC,
135 CPCAP_REG_MT1,
136 CPCAP_REG_MT2,
137 CPCAP_REG_MT3,
Ben Cheng654325d2012-03-07 21:13:49 -0800138/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700139 CPCAP_REG_PF,
Nick Pellyb3765b22010-08-16 15:31:01 -0700140 CPCAP_REG_SCC,
141 CPCAP_REG_SW1,
142 CPCAP_REG_SW2,
Ben Cheng654325d2012-03-07 21:13:49 -0800143/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700144 CPCAP_REG_UCTM,
145 CPCAP_REG_TOD1,
146 CPCAP_REG_TOD2,
147 CPCAP_REG_TODA1,
Ben Cheng654325d2012-03-07 21:13:49 -0800148/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700149 CPCAP_REG_TODA2,
150 CPCAP_REG_DAY,
151 CPCAP_REG_DAYA,
152 CPCAP_REG_VAL1,
Ben Cheng654325d2012-03-07 21:13:49 -0800153/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700154 CPCAP_REG_VAL2,
Nick Pellyb3765b22010-08-16 15:31:01 -0700155 CPCAP_REG_SDVSPLL,
156 CPCAP_REG_SI2CC1,
157 CPCAP_REG_Si2CC2,
Ben Cheng654325d2012-03-07 21:13:49 -0800158/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700159 CPCAP_REG_S1C1,
160 CPCAP_REG_S1C2,
161 CPCAP_REG_S2C1,
162 CPCAP_REG_S2C2,
Ben Cheng654325d2012-03-07 21:13:49 -0800163/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700164 CPCAP_REG_S3C,
165 CPCAP_REG_S4C1,
166 CPCAP_REG_S4C2,
167 CPCAP_REG_S5C,
Ben Cheng654325d2012-03-07 21:13:49 -0800168/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700169 CPCAP_REG_S6C,
170 CPCAP_REG_VCAMC,
171 CPCAP_REG_VCSIC,
172 CPCAP_REG_VDACC,
Ben Cheng654325d2012-03-07 21:13:49 -0800173/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700174 CPCAP_REG_VDIGC,
175 CPCAP_REG_VFUSEC,
176 CPCAP_REG_VHVIOC,
177 CPCAP_REG_VSDIOC,
Ben Cheng654325d2012-03-07 21:13:49 -0800178/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700179 CPCAP_REG_VPLLC,
180 CPCAP_REG_VRF1C,
181 CPCAP_REG_VRF2C,
182 CPCAP_REG_VRFREFC,
Ben Cheng654325d2012-03-07 21:13:49 -0800183/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700184 CPCAP_REG_VWLAN1C,
185 CPCAP_REG_VWLAN2C,
186 CPCAP_REG_VSIMC,
187 CPCAP_REG_VVIBC,
Ben Cheng654325d2012-03-07 21:13:49 -0800188/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700189 CPCAP_REG_VUSBC,
190 CPCAP_REG_VUSBINT1C,
191 CPCAP_REG_VUSBINT2C,
192 CPCAP_REG_URT,
Ben Cheng654325d2012-03-07 21:13:49 -0800193/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700194 CPCAP_REG_URM1,
195 CPCAP_REG_URM2,
Nick Pellyb3765b22010-08-16 15:31:01 -0700196 CPCAP_REG_VAUDIOC,
197 CPCAP_REG_CC,
Ben Cheng654325d2012-03-07 21:13:49 -0800198/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700199 CPCAP_REG_CDI,
200 CPCAP_REG_SDAC,
201 CPCAP_REG_SDACDI,
202 CPCAP_REG_TXI,
Ben Cheng654325d2012-03-07 21:13:49 -0800203/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700204 CPCAP_REG_TXMP,
205 CPCAP_REG_RXOA,
206 CPCAP_REG_RXVC,
207 CPCAP_REG_RXCOA,
Ben Cheng654325d2012-03-07 21:13:49 -0800208/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700209 CPCAP_REG_RXSDOA,
210 CPCAP_REG_RXEPOA,
211 CPCAP_REG_RXLL,
212 CPCAP_REG_A2LA,
Ben Cheng654325d2012-03-07 21:13:49 -0800213/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700214 CPCAP_REG_MIPIS1,
215 CPCAP_REG_MIPIS2,
216 CPCAP_REG_MIPIS3,
217 CPCAP_REG_LVAB,
Ben Cheng654325d2012-03-07 21:13:49 -0800218/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700219 CPCAP_REG_CCC1,
220 CPCAP_REG_CRM,
221 CPCAP_REG_CCCC2,
222 CPCAP_REG_CCS1,
Ben Cheng654325d2012-03-07 21:13:49 -0800223/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700224 CPCAP_REG_CCS2,
225 CPCAP_REG_CCA1,
226 CPCAP_REG_CCA2,
227 CPCAP_REG_CCM,
Ben Cheng654325d2012-03-07 21:13:49 -0800228/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700229 CPCAP_REG_CCO,
230 CPCAP_REG_CCI,
Nick Pellyb3765b22010-08-16 15:31:01 -0700231 CPCAP_REG_ADCC1,
232 CPCAP_REG_ADCC2,
Ben Cheng654325d2012-03-07 21:13:49 -0800233/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700234 CPCAP_REG_ADCD0,
235 CPCAP_REG_ADCD1,
236 CPCAP_REG_ADCD2,
237 CPCAP_REG_ADCD3,
Ben Cheng654325d2012-03-07 21:13:49 -0800238/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700239 CPCAP_REG_ADCD4,
240 CPCAP_REG_ADCD5,
241 CPCAP_REG_ADCD6,
242 CPCAP_REG_ADCD7,
Ben Cheng654325d2012-03-07 21:13:49 -0800243/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700244 CPCAP_REG_ADCAL1,
245 CPCAP_REG_ADCAL2,
Nick Pellyb3765b22010-08-16 15:31:01 -0700246 CPCAP_REG_USBC1,
247 CPCAP_REG_USBC2,
Ben Cheng654325d2012-03-07 21:13:49 -0800248/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700249 CPCAP_REG_USBC3,
250 CPCAP_REG_UVIDL,
251 CPCAP_REG_UVIDH,
252 CPCAP_REG_UPIDL,
Ben Cheng654325d2012-03-07 21:13:49 -0800253/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700254 CPCAP_REG_UPIDH,
255 CPCAP_REG_UFC1,
256 CPCAP_REG_UFC2,
257 CPCAP_REG_UFC3,
Ben Cheng654325d2012-03-07 21:13:49 -0800258/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700259 CPCAP_REG_UIC1,
260 CPCAP_REG_UIC2,
261 CPCAP_REG_UIC3,
262 CPCAP_REG_USBOTG1,
Ben Cheng654325d2012-03-07 21:13:49 -0800263/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700264 CPCAP_REG_USBOTG2,
265 CPCAP_REG_USBOTG3,
266 CPCAP_REG_UIER1,
267 CPCAP_REG_UIER2,
Ben Cheng654325d2012-03-07 21:13:49 -0800268/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700269 CPCAP_REG_UIER3,
270 CPCAP_REG_UIEF1,
271 CPCAP_REG_UIEF2,
272 CPCAP_REG_UIEF3,
Ben Cheng654325d2012-03-07 21:13:49 -0800273/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700274 CPCAP_REG_UIS,
275 CPCAP_REG_UIL,
276 CPCAP_REG_USBD,
277 CPCAP_REG_SCR1,
Ben Cheng654325d2012-03-07 21:13:49 -0800278/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700279 CPCAP_REG_SCR2,
280 CPCAP_REG_SCR3,
281 CPCAP_REG_VMC,
282 CPCAP_REG_OWDC,
Ben Cheng654325d2012-03-07 21:13:49 -0800283/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700284 CPCAP_REG_GPIO0,
285 CPCAP_REG_GPIO1,
286 CPCAP_REG_GPIO2,
287 CPCAP_REG_GPIO3,
Ben Cheng654325d2012-03-07 21:13:49 -0800288/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700289 CPCAP_REG_GPIO4,
290 CPCAP_REG_GPIO5,
291 CPCAP_REG_GPIO6,
Nick Pellyb3765b22010-08-16 15:31:01 -0700292 CPCAP_REG_MDLC,
Ben Cheng654325d2012-03-07 21:13:49 -0800293/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700294 CPCAP_REG_KLC,
295 CPCAP_REG_ADLC,
296 CPCAP_REG_REDC,
297 CPCAP_REG_GREENC,
Ben Cheng654325d2012-03-07 21:13:49 -0800298/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700299 CPCAP_REG_BLUEC,
300 CPCAP_REG_CFC,
301 CPCAP_REG_ABC,
302 CPCAP_REG_BLEDC,
Ben Cheng654325d2012-03-07 21:13:49 -0800303/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700304 CPCAP_REG_CLEDC,
Nick Pellyb3765b22010-08-16 15:31:01 -0700305 CPCAP_REG_OW1C,
306 CPCAP_REG_OW1D,
307 CPCAP_REG_OW1I,
Ben Cheng654325d2012-03-07 21:13:49 -0800308/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700309 CPCAP_REG_OW1IE,
310 CPCAP_REG_OW1,
311 CPCAP_REG_OW2C,
312 CPCAP_REG_OW2D,
Ben Cheng654325d2012-03-07 21:13:49 -0800313/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700314 CPCAP_REG_OW2I,
315 CPCAP_REG_OW2IE,
316 CPCAP_REG_OW2,
317 CPCAP_REG_OW3C,
Ben Cheng654325d2012-03-07 21:13:49 -0800318/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700319 CPCAP_REG_OW3D,
320 CPCAP_REG_OW3I,
321 CPCAP_REG_OW3IE,
322 CPCAP_REG_OW3,
Ben Cheng654325d2012-03-07 21:13:49 -0800323/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700324 CPCAP_REG_GCAIC,
325 CPCAP_REG_GCAIM,
326 CPCAP_REG_LGDIR,
327 CPCAP_REG_LGPU,
Ben Cheng654325d2012-03-07 21:13:49 -0800328/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700329 CPCAP_REG_LGPIN,
330 CPCAP_REG_LGMASK,
331 CPCAP_REG_LDEB,
332 CPCAP_REG_LGDET,
Ben Cheng654325d2012-03-07 21:13:49 -0800333/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700334 CPCAP_REG_LMISC,
335 CPCAP_REG_LMACE,
Nick Pellyb3765b22010-08-16 15:31:01 -0700336 CPCAP_REG_END = CPCAP_REG_LMACE,
Nick Pellyb3765b22010-08-16 15:31:01 -0700337 CPCAP_REG_MAX
Ben Cheng654325d2012-03-07 21:13:49 -0800338/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700339 = CPCAP_REG_END,
Nick Pellyb3765b22010-08-16 15:31:01 -0700340 CPCAP_REG_SIZE = CPCAP_REG_MAX + 1,
341 CPCAP_REG_UNUSED = CPCAP_REG_MAX + 2,
342};
Ben Cheng654325d2012-03-07 21:13:49 -0800343/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700344enum {
345 CPCAP_IOCTL_NUM_TEST__START,
346 CPCAP_IOCTL_NUM_TEST_READ_REG,
347 CPCAP_IOCTL_NUM_TEST_WRITE_REG,
Ben Cheng654325d2012-03-07 21:13:49 -0800348/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700349 CPCAP_IOCTL_NUM_TEST__END,
Nick Pellyb3765b22010-08-16 15:31:01 -0700350 CPCAP_IOCTL_NUM_ADC__START,
351 CPCAP_IOCTL_NUM_ADC_PHASE,
352 CPCAP_IOCTL_NUM_ADC__END,
Ben Cheng654325d2012-03-07 21:13:49 -0800353/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700354 CPCAP_IOCTL_NUM_BATT__START,
355 CPCAP_IOCTL_NUM_BATT_DISPLAY_UPDATE,
356 CPCAP_IOCTL_NUM_BATT_ATOD_ASYNC,
357 CPCAP_IOCTL_NUM_BATT_ATOD_SYNC,
Ben Cheng654325d2012-03-07 21:13:49 -0800358/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700359 CPCAP_IOCTL_NUM_BATT_ATOD_READ,
360 CPCAP_IOCTL_NUM_BATT__END,
Nick Pellyb3765b22010-08-16 15:31:01 -0700361 CPCAP_IOCTL_NUM_UC__START,
362 CPCAP_IOCTL_NUM_UC_MACRO_START,
Ben Cheng654325d2012-03-07 21:13:49 -0800363/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700364 CPCAP_IOCTL_NUM_UC_MACRO_STOP,
365 CPCAP_IOCTL_NUM_UC_GET_VENDOR,
366 CPCAP_IOCTL_NUM_UC_SET_TURBO_MODE,
367 CPCAP_IOCTL_NUM_UC__END,
Ben Cheng654325d2012-03-07 21:13:49 -0800368/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700369 CPCAP_IOCTL_NUM_ACCY__START,
370 CPCAP_IOCTL_NUM_ACCY_WHISPER,
371 CPCAP_IOCTL_NUM_ACCY__END,
372};
Ben Cheng654325d2012-03-07 21:13:49 -0800373/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700374enum cpcap_irqs {
375 CPCAP_IRQ__START,
376 CPCAP_IRQ_HSCLK = CPCAP_IRQ_INT1_INDEX,
377 CPCAP_IRQ_PRIMAC,
Ben Cheng654325d2012-03-07 21:13:49 -0800378/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700379 CPCAP_IRQ_SECMAC,
380 CPCAP_IRQ_LOWBPL,
381 CPCAP_IRQ_SEC2PRI,
382 CPCAP_IRQ_LOWBPH,
Ben Cheng654325d2012-03-07 21:13:49 -0800383/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700384 CPCAP_IRQ_EOL,
385 CPCAP_IRQ_TS,
386 CPCAP_IRQ_ADCDONE,
387 CPCAP_IRQ_HS,
Ben Cheng654325d2012-03-07 21:13:49 -0800388/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700389 CPCAP_IRQ_MB2,
390 CPCAP_IRQ_VBUSOV,
391 CPCAP_IRQ_RVRS_CHRG,
392 CPCAP_IRQ_CHRG_DET,
Ben Cheng654325d2012-03-07 21:13:49 -0800393/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700394 CPCAP_IRQ_IDFLOAT,
395 CPCAP_IRQ_IDGND,
Nick Pellyb3765b22010-08-16 15:31:01 -0700396 CPCAP_IRQ_SE1 = CPCAP_IRQ_INT2_INDEX,
397 CPCAP_IRQ_SESSEND,
Ben Cheng654325d2012-03-07 21:13:49 -0800398/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700399 CPCAP_IRQ_SESSVLD,
400 CPCAP_IRQ_VBUSVLD,
401 CPCAP_IRQ_CHRG_CURR1,
402 CPCAP_IRQ_CHRG_CURR2,
Ben Cheng654325d2012-03-07 21:13:49 -0800403/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700404 CPCAP_IRQ_RVRS_MODE,
405 CPCAP_IRQ_ON,
406 CPCAP_IRQ_ON2,
407 CPCAP_IRQ_CLK,
Ben Cheng654325d2012-03-07 21:13:49 -0800408/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700409 CPCAP_IRQ_1HZ,
410 CPCAP_IRQ_PTT,
411 CPCAP_IRQ_SE0CONN,
412 CPCAP_IRQ_CHRG_SE1B,
Ben Cheng654325d2012-03-07 21:13:49 -0800413/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700414 CPCAP_IRQ_UART_ECHO_OVERRUN,
415 CPCAP_IRQ_EXTMEMHD,
Nick Pellyb3765b22010-08-16 15:31:01 -0700416 CPCAP_IRQ_WARM = CPCAP_IRQ_INT3_INDEX,
417 CPCAP_IRQ_SYSRSTR,
Ben Cheng654325d2012-03-07 21:13:49 -0800418/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700419 CPCAP_IRQ_SOFTRST,
420 CPCAP_IRQ_DIEPWRDWN,
421 CPCAP_IRQ_DIETEMPH,
422 CPCAP_IRQ_PC,
Ben Cheng654325d2012-03-07 21:13:49 -0800423/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700424 CPCAP_IRQ_OFLOWSW,
425 CPCAP_IRQ_TODA,
426 CPCAP_IRQ_OPT_SEL_DTCH,
427 CPCAP_IRQ_OPT_SEL_STATE,
Ben Cheng654325d2012-03-07 21:13:49 -0800428/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700429 CPCAP_IRQ_ONEWIRE1,
430 CPCAP_IRQ_ONEWIRE2,
431 CPCAP_IRQ_ONEWIRE3,
432 CPCAP_IRQ_UCRESET,
Ben Cheng654325d2012-03-07 21:13:49 -0800433/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700434 CPCAP_IRQ_PWRGOOD,
435 CPCAP_IRQ_USBDPLLCLK,
Nick Pellyb3765b22010-08-16 15:31:01 -0700436 CPCAP_IRQ_DPI = CPCAP_IRQ_INT4_INDEX,
437 CPCAP_IRQ_DMI,
Ben Cheng654325d2012-03-07 21:13:49 -0800438/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700439 CPCAP_IRQ_UCBUSY,
440 CPCAP_IRQ_GCAI_CURR1,
441 CPCAP_IRQ_GCAI_CURR2,
442 CPCAP_IRQ_SB_MAX_RETRANSMIT_ERR,
Ben Cheng654325d2012-03-07 21:13:49 -0800443/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700444 CPCAP_IRQ_BATTDETB,
445 CPCAP_IRQ_PRIHALT,
446 CPCAP_IRQ_SECHALT,
447 CPCAP_IRQ_CC_CAL,
Ben Cheng654325d2012-03-07 21:13:49 -0800448/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700449 CPCAP_IRQ_UC_PRIROMR = CPCAP_IRQ_INT5_INDEX,
450 CPCAP_IRQ_UC_PRIRAMW,
451 CPCAP_IRQ_UC_PRIRAMR,
452 CPCAP_IRQ_UC_USEROFF,
Ben Cheng654325d2012-03-07 21:13:49 -0800453/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700454 CPCAP_IRQ_UC_PRIMACRO_4,
455 CPCAP_IRQ_UC_PRIMACRO_5,
456 CPCAP_IRQ_UC_PRIMACRO_6,
457 CPCAP_IRQ_UC_PRIMACRO_7,
Ben Cheng654325d2012-03-07 21:13:49 -0800458/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700459 CPCAP_IRQ_UC_PRIMACRO_8,
460 CPCAP_IRQ_UC_PRIMACRO_9,
461 CPCAP_IRQ_UC_PRIMACRO_10,
462 CPCAP_IRQ_UC_PRIMACRO_11,
Ben Cheng654325d2012-03-07 21:13:49 -0800463/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700464 CPCAP_IRQ_UC_PRIMACRO_12,
465 CPCAP_IRQ_UC_PRIMACRO_13,
466 CPCAP_IRQ_UC_PRIMACRO_14,
467 CPCAP_IRQ_UC_PRIMACRO_15,
Ben Cheng654325d2012-03-07 21:13:49 -0800468/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700469 CPCAP_IRQ__NUM
470};
Nick Pellyb3765b22010-08-16 15:31:01 -0700471enum cpcap_adc_bank0 {
472 CPCAP_ADC_AD0_BATTDETB,
Ben Cheng654325d2012-03-07 21:13:49 -0800473/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700474 CPCAP_ADC_BATTP,
475 CPCAP_ADC_VBUS,
476 CPCAP_ADC_AD3,
477 CPCAP_ADC_BPLUS_AD4,
Ben Cheng654325d2012-03-07 21:13:49 -0800478/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700479 CPCAP_ADC_CHG_ISENSE,
480 CPCAP_ADC_BATTI_ADC,
481 CPCAP_ADC_USB_ID,
Nick Pellyb3765b22010-08-16 15:31:01 -0700482 CPCAP_ADC_BANK0_NUM,
Ben Cheng654325d2012-03-07 21:13:49 -0800483/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700484};
Nick Pellyb3765b22010-08-16 15:31:01 -0700485enum cpcap_adc_bank1 {
486 CPCAP_ADC_AD8,
487 CPCAP_ADC_AD9,
Ben Cheng654325d2012-03-07 21:13:49 -0800488/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700489 CPCAP_ADC_LICELL,
490 CPCAP_ADC_HV_BATTP,
491 CPCAP_ADC_TSX1_AD12,
492 CPCAP_ADC_TSX2_AD13,
Ben Cheng654325d2012-03-07 21:13:49 -0800493/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700494 CPCAP_ADC_TSY1_AD14,
495 CPCAP_ADC_TSY2_AD15,
Nick Pellyb3765b22010-08-16 15:31:01 -0700496 CPCAP_ADC_BANK1_NUM,
497};
Ben Cheng654325d2012-03-07 21:13:49 -0800498/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700499enum cpcap_adc_format {
500 CPCAP_ADC_FORMAT_RAW,
501 CPCAP_ADC_FORMAT_PHASED,
502 CPCAP_ADC_FORMAT_CONVERTED,
Ben Cheng654325d2012-03-07 21:13:49 -0800503/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700504};
Nick Pellyb3765b22010-08-16 15:31:01 -0700505enum cpcap_adc_timing {
506 CPCAP_ADC_TIMING_IMM,
507 CPCAP_ADC_TIMING_IN,
Ben Cheng654325d2012-03-07 21:13:49 -0800508/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700509 CPCAP_ADC_TIMING_OUT,
510};
Nick Pellyb3765b22010-08-16 15:31:01 -0700511enum cpcap_adc_type {
512 CPCAP_ADC_TYPE_BANK_0,
Ben Cheng654325d2012-03-07 21:13:49 -0800513/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700514 CPCAP_ADC_TYPE_BANK_1,
515 CPCAP_ADC_TYPE_BATT_PI,
516};
Nick Pellyb3765b22010-08-16 15:31:01 -0700517enum cpcap_macro {
Ben Cheng654325d2012-03-07 21:13:49 -0800518/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700519 CPCAP_MACRO_ROMR,
520 CPCAP_MACRO_RAMW,
521 CPCAP_MACRO_RAMR,
522 CPCAP_MACRO_USEROFF,
Ben Cheng654325d2012-03-07 21:13:49 -0800523/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700524 CPCAP_MACRO_4,
525 CPCAP_MACRO_5,
526 CPCAP_MACRO_6,
527 CPCAP_MACRO_7,
Ben Cheng654325d2012-03-07 21:13:49 -0800528/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700529 CPCAP_MACRO_8,
530 CPCAP_MACRO_9,
531 CPCAP_MACRO_10,
532 CPCAP_MACRO_11,
Ben Cheng654325d2012-03-07 21:13:49 -0800533/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700534 CPCAP_MACRO_12,
535 CPCAP_MACRO_13,
536 CPCAP_MACRO_14,
537 CPCAP_MACRO_15,
Ben Cheng654325d2012-03-07 21:13:49 -0800538/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700539 CPCAP_MACRO__END,
540};
Nick Pellyb3765b22010-08-16 15:31:01 -0700541enum cpcap_vendor {
542 CPCAP_VENDOR_ST,
Ben Cheng654325d2012-03-07 21:13:49 -0800543/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700544 CPCAP_VENDOR_TI,
545};
Nick Pellyb3765b22010-08-16 15:31:01 -0700546enum cpcap_revision {
547 CPCAP_REVISION_1_0 = 0x08,
Ben Cheng654325d2012-03-07 21:13:49 -0800548/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700549 CPCAP_REVISION_1_1 = 0x09,
550 CPCAP_REVISION_2_0 = 0x10,
551 CPCAP_REVISION_2_1 = 0x11,
552};
Ben Cheng654325d2012-03-07 21:13:49 -0800553/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700554enum cpcap_batt_usb_model {
555 CPCAP_BATT_USB_MODEL_NONE,
556 CPCAP_BATT_USB_MODEL_USB,
557 CPCAP_BATT_USB_MODEL_FACTORY,
Ben Cheng654325d2012-03-07 21:13:49 -0800558/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700559};
Nick Pellyb3765b22010-08-16 15:31:01 -0700560struct cpcap_spi_init_data {
561 enum cpcap_reg reg;
562 unsigned short data;
Ben Cheng654325d2012-03-07 21:13:49 -0800563/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700564};
Nick Pellyb3765b22010-08-16 15:31:01 -0700565struct cpcap_adc_ato {
566 unsigned short ato_in;
567 unsigned short atox_in;
Ben Cheng654325d2012-03-07 21:13:49 -0800568/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700569 unsigned short adc_ps_factor_in;
570 unsigned short atox_ps_factor_in;
571 unsigned short ato_out;
572 unsigned short atox_out;
Ben Cheng654325d2012-03-07 21:13:49 -0800573/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700574 unsigned short adc_ps_factor_out;
575 unsigned short atox_ps_factor_out;
576};
Nick Pellyb3765b22010-08-16 15:31:01 -0700577struct cpcap_batt_data {
Ben Cheng654325d2012-03-07 21:13:49 -0800578/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700579 int status;
580 int health;
581 int present;
582 int capacity;
Ben Cheng654325d2012-03-07 21:13:49 -0800583/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700584 int batt_volt;
585 int batt_temp;
586};
Nick Pellyb3765b22010-08-16 15:31:01 -0700587struct cpcap_batt_ac_data {
Ben Cheng654325d2012-03-07 21:13:49 -0800588/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700589 int online;
590};
Nick Pellyb3765b22010-08-16 15:31:01 -0700591struct cpcap_batt_usb_data {
592 int online;
Ben Cheng654325d2012-03-07 21:13:49 -0800593/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700594 int current_now;
595 enum cpcap_batt_usb_model model;
596};
Nick Pellyb3765b22010-08-16 15:31:01 -0700597struct cpcap_device;
Ben Cheng654325d2012-03-07 21:13:49 -0800598/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700599struct cpcap_adc_us_request {
600 enum cpcap_adc_format format;
601 enum cpcap_adc_timing timing;
602 enum cpcap_adc_type type;
Ben Cheng654325d2012-03-07 21:13:49 -0800603/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700604 int status;
605 int result[CPCAP_ADC_BANK0_NUM];
606};
Nick Pellyb3765b22010-08-16 15:31:01 -0700607struct cpcap_adc_phase {
Ben Cheng654325d2012-03-07 21:13:49 -0800608/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700609 signed char offset_batti;
610 unsigned char slope_batti;
611 signed char offset_chrgi;
612 unsigned char slope_chrgi;
Ben Cheng654325d2012-03-07 21:13:49 -0800613/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700614 signed char offset_battp;
615 unsigned char slope_battp;
616 signed char offset_bp;
617 unsigned char slope_bp;
Ben Cheng654325d2012-03-07 21:13:49 -0800618/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700619 signed char offset_battt;
620 unsigned char slope_battt;
621 signed char offset_chrgv;
622 unsigned char slope_chrgv;
Ben Cheng654325d2012-03-07 21:13:49 -0800623/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700624};
Nick Pellyb3765b22010-08-16 15:31:01 -0700625struct cpcap_regacc {
626 unsigned short reg;
627 unsigned short value;
Ben Cheng654325d2012-03-07 21:13:49 -0800628/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700629 unsigned short mask;
630};
Nick Pellyb3765b22010-08-16 15:31:01 -0700631struct cpcap_whisper_request {
632 unsigned int cmd;
Ben Cheng654325d2012-03-07 21:13:49 -0800633/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700634 char dock_id[CPCAP_WHISPER_ID_SIZE];
Iliyan Malchevbb3bcbc2010-11-02 15:58:36 -0700635 char dock_prop[CPCAP_WHISPER_PROP_SIZE];
Nick Pellyb3765b22010-08-16 15:31:01 -0700636};
Nick Pellyb3765b22010-08-16 15:31:01 -0700637#define CPCAP_IOCTL_TEST_READ_REG _IOWR(0, CPCAP_IOCTL_NUM_TEST_READ_REG, struct cpcap_regacc*)
Ben Cheng654325d2012-03-07 21:13:49 -0800638/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700639#define CPCAP_IOCTL_TEST_WRITE_REG _IOWR(0, CPCAP_IOCTL_NUM_TEST_WRITE_REG, struct cpcap_regacc*)
Nick Pellyb3765b22010-08-16 15:31:01 -0700640#define CPCAP_IOCTL_ADC_PHASE _IOWR(0, CPCAP_IOCTL_NUM_ADC_PHASE, struct cpcap_adc_phase*)
Nick Pellyb3765b22010-08-16 15:31:01 -0700641#define CPCAP_IOCTL_BATT_DISPLAY_UPDATE _IOW(0, CPCAP_IOCTL_NUM_BATT_DISPLAY_UPDATE, struct cpcap_batt_data*)
Nick Pellyb3765b22010-08-16 15:31:01 -0700642#define CPCAP_IOCTL_BATT_ATOD_ASYNC _IOW(0, CPCAP_IOCTL_NUM_BATT_ATOD_ASYNC, struct cpcap_adc_us_request*)
Ben Cheng654325d2012-03-07 21:13:49 -0800643/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700644#define CPCAP_IOCTL_BATT_ATOD_SYNC _IOWR(0, CPCAP_IOCTL_NUM_BATT_ATOD_SYNC, struct cpcap_adc_us_request*)
Nick Pellyb3765b22010-08-16 15:31:01 -0700645#define CPCAP_IOCTL_BATT_ATOD_READ _IOWR(0, CPCAP_IOCTL_NUM_BATT_ATOD_READ, struct cpcap_adc_us_request*)
Nick Pellyb3765b22010-08-16 15:31:01 -0700646#define CPCAP_IOCTL_UC_MACRO_START _IOWR(0, CPCAP_IOCTL_NUM_UC_MACRO_START, enum cpcap_macro)
Nick Pellyb3765b22010-08-16 15:31:01 -0700647#define CPCAP_IOCTL_UC_MACRO_STOP _IOWR(0, CPCAP_IOCTL_NUM_UC_MACRO_STOP, enum cpcap_macro)
Ben Cheng654325d2012-03-07 21:13:49 -0800648/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Nick Pellyb3765b22010-08-16 15:31:01 -0700649#define CPCAP_IOCTL_UC_GET_VENDOR _IOWR(0, CPCAP_IOCTL_NUM_UC_GET_VENDOR, enum cpcap_vendor)
Nick Pellyb3765b22010-08-16 15:31:01 -0700650#define CPCAP_IOCTL_UC_SET_TURBO_MODE _IOW(0, CPCAP_IOCTL_NUM_UC_SET_TURBO_MODE, unsigned short)
Nick Pellyb3765b22010-08-16 15:31:01 -0700651#define CPCAP_IOCTL_ACCY_WHISPER _IOW(0, CPCAP_IOCTL_NUM_ACCY_WHISPER, struct cpcap_whisper_request*)
Nick Pellyb3765b22010-08-16 15:31:01 -0700652#endif
Ben Cheng654325d2012-03-07 21:13:49 -0800653/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */