soc/intel/denverton_ns: Remove variable set but not used
[coreboot.git] / util / superiotool / ite.c
blob8f1e2ea019fe6903d938da63babcc227fc780f6f
1 /*
2 * This file is part of the superiotool project.
4 * Copyright (C) 2007 Carl-Daniel Hailfinger
5 * Copyright (C) 2007-2008 Uwe Hermann <uwe@hermann-uwe.de>
6 * Copyright (C) 2018 Libretrend LDA
7 * Copyright (C) 2019 Protectli
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
14 * This program is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Public License for more details.
20 #include "superiotool.h"
22 #define CHIP_ID_BYTE1_REG 0x20
23 #define CHIP_ID_BYTE2_REG 0x21
24 #define CHIP_VERSION_REG 0x22
25 #define ISA_PNP_ADDR 0x279
27 static const struct superio_registers reg_table[] = {
28 {0x8228, "IT8228E", {
29 {EOT}}},
30 {0x8500, "IT8500B/E", {
31 {NOLDN, NULL,
32 {0x20,0x21,0x22,0x23,0x25,0x2d,0x2e,0x2f,0x30,EOT},
33 {0x85,0x00,0x01,0x01,0x00,0x00,NANA,NANA,0x00,EOT}},
34 {0x04, "System Wake-Up Control (SWUC)",
35 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
36 {0x00,0x00,0x00,0x00,0x00,0x00,0x01,EOT}},
37 {0x05, "KBC/Mouse Interface",
38 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
39 {0x00,0x00,0x00,0x00,0x00,0x0c,0x01,EOT}},
40 {0x06, "KBC/Keyboard Interface",
41 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
42 {0x00,0x00,0x60,0x00,0x64,0x01,0x01,EOT}},
43 {0x0f, "Shared Memory/Flash Interface (SMFI)",
44 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf4,EOT},
45 {0x00,0x00,0x00,0x00,0x00,0x00,0x00,NANA,EOT}},
46 {0x10, "BRAM",
47 {0x30,0x62,0x63,0x70,0x71,0xf3,0xf4,0xf5,EOT},
48 {0x00,0x00,0x72,0x08,0x01,NANA,NANA,NANA,EOT}},
49 {0x11, "Power Management I/F Channel 1 (PMC1)",
50 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
51 {0x00,0x00,0x62,0x00,0x66,0x01,0x01,EOT}},
52 {0x12, "Power Management I/F Channel 2 (PMC2)",
53 {0x30,0x60,0x61,0x62,0x63,0x64,0x65,0x70,0x71,0xf0,EOT},
54 {0x00,0x00,0x68,0x00,0x6c,0x00,0x00,0x01,0x01,NANA,EOT}},
55 {EOT}}},
56 {0x8502, "IT8502E/TE/G", {
57 {NOLDN, NULL,
58 {0x20,0x21,0x22,0x23,0x24,0x25,0x26,0x27,0x28,0x29,
59 0x2A,0x2B,0x2C,0x2D,0x2E,EOT},
60 {0x85,0x02,0x71,0x01,NANA,0x00,0x00,NANA,NANA,NANA,
61 NANA,NANA,NANA,0x00,NANA,EOT}},
62 {0x1, "UART1",
63 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
64 {0x00,0x03,0xf8,0x00,0x00,0x04,0x02,0x00,EOT}},
65 {0x4, "System Wake-Up",
66 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
67 {0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,EOT}},
68 {0x5, "Mouse",
69 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
70 {0x01,0x00,0x00,0x00,0x00,0x0C,0x01,NANA,EOT}},
71 {0x6, "Keyboard",
72 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
73 {0x01,0x00,0x60,0x00,0x64,0x01,0x01,NANA,EOT}},
74 {0xf, "Shared Memory/Flash",
75 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf4,0xf5,
76 0xf6,EOT},
77 {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
78 0x00,EOT}},
79 {0x10, "BRAM",
80 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf3,0xf4,
81 0xf5,EOT},
82 {0x00,0x00,0x70,0x00,0x72,0x08,0x01,NANA,NANA,
83 NANA,EOT}},
84 {0x11, "Power Channel 1",
85 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
87 {0x00,0x00,0x62,0x00,0x66,0x01,0x01,EOT}},
88 {0x12, "Power Channel 2",
89 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
90 {0x00,0x00,0x68,0x00,0x6c,0x01,0x01,EOT}},
91 {0x17, "Power Channel 3",
92 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
93 {0x00,0x00,0x6a,0x00,0x6e,0x01,0x01,EOT}},
94 {EOT}}},
95 {0x8510, "IT8510E/TE/G", {
96 {NOLDN, "Chip ID",
97 {0x20,0x21, EOT},
98 {0x85,0x10, EOT}},
99 {NOLDN, "Chip Version",
100 {0x22,EOT},
101 {0x21,EOT}},
102 {NOLDN, "Super I/O Control Reigster (SIOCTRL)",
103 {0x23,EOT},
104 {0x01,EOT}},
105 {NOLDN, "Super I/O Configuration Register (SIOIRQ)",
106 {0x25,EOT},
107 {0x00,EOT}},
108 {NOLDN, "Super I/O General Purpose Register (SIOGP)",
109 {0x26,EOT},
110 {0x00,EOT}},
111 {NOLDN, "Super I/O Power Mode Register (SIOPWR)",
112 {0x2d,EOT},
113 {0x00,EOT}},
114 {NOLDN, "Logical Device Activate Register (LDA)",
115 {0x30,EOT},
116 {0x00,EOT}},
117 {NOLDN, "I/O Port Base Address for Descriptor 0 (IOBAD0)",
118 {0x60,0x61,EOT},
119 {NANA,NANA,EOT}},
120 {NOLDN, "I/O Port Base Address for Descriptor 1 (IOBAD1)",
121 {0x62,0x63,EOT},
122 {NANA,NANA,EOT}},
123 {NOLDN, "Interrupt Request Number and Wake-Up on IRQ Enable (IRQNUMX)",
124 {0x70,EOT},
125 {NANA,EOT}},
126 {NOLDN, "Interrupt Request Type Select (IRQTP)",
127 {0x71,EOT},
128 {NANA,EOT}},
129 {NOLDN, "DMA Channel Select 0 (DMAS0)",
130 {0x74,EOT},
131 {0x04,EOT}},
132 {NOLDN, "DMA Channel Select 1 (DMAS1)",
133 {0x75,EOT},
134 {0x04,EOT}},
135 {0x4, "System Wakup-Up (SWUC)",
136 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
137 {0x00,0x00,0x00,0x00,0x00,0x00,0x03,EOT}},
138 {0x5, "Keyboard/Mouse",
139 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
140 {0x00,0x00,0x00,0x00,0x00,0x0c,0x03,EOT}},
141 {0x6, "Keyboard/Mouse",
142 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
143 {0x00,0x00,0x60,0x00,0x64,0x01,0x03,EOT}},
144 {0xf, "Shared Memory/Flash Interface (SMFI)",
145 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf4,0xf5,0xf6,0xf7,0xf8,EOT},
146 {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,EOT}},
147 {0x10, "Real Time Clock (RTC)",
148 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,0xf1,0xf2,EOT},
149 {0x00,0x00,0x70,0x00,0x72,0x08,0x00,0x00,0x49,0x4a,EOT}},
150 {0x11, "Power Management Interface Channel 1",
151 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
152 {0x00,0x00,0x62,0x00,0x66,0x01,0x03,EOT}},
153 {0x12, "Power Management Interface Channel 2",
154 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
155 {0x00,0x00,0x68,0x00,0x6c,0x01,0x03,EOT}},
156 {EOT}}},
157 {0x8511, "IT8511E/TE/G", {
158 {NOLDN, NULL,
159 {0x20,0x21,0x22,0x23,0x24,0x25,0x26,0x27,0x28,0x29,
160 0x2A,0x2B,0x2C,0x2D,0x2E,EOT},
161 {0x85,0x11,0x10,0x01,NANA,0x00,0x00,NANA,NANA,NANA,
162 NANA,NANA,NANA,0x00,NANA,EOT}},
163 {0x4, "System Wake-Up",
164 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
165 {0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,EOT}},
166 {0x5, "Mouse",
167 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
168 {0x01,0x00,0x00,0x00,0x00,0x0C,0x03,NANA,EOT}},
169 {0x6, "Keyboard",
170 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
171 {0x01,0x00,0x60,0x00,0x64,0x01,0x03,NANA,EOT}},
172 {0xf, "Shared Memory/Flash",
173 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf4,0xf5,
174 0xf6,EOT},
175 {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
176 0x00,EOT}},
177 {0x10, "Real-Time Clock",
178 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,0xf1,
179 0xf2,0xf3,0xf4,0xf5,EOT},
180 {0x00,0x00,0x70,0x00,0x72,0x08,0x00,0x00,0x49,
181 0x4A,NANA,NANA,NANA,EOT}},
182 {0x11, "Power Channel 1",
183 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
184 {0x00,0x00,0x62,0x00,0x66,0x01,0x03,EOT}},
185 {0x12, "Power Channel 2",
186 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
187 {0x00,0x00,0x68,0x00,0x6c,0x01,0x03,EOT}},
188 {EOT}}},
189 {0x8512, "IT8512E/F/G", {
190 {NOLDN, NULL,
191 {0x20,0x21,0x22,0x23,0x24,0x25,0x26,0x27,0x28,0x29,
192 0x2A,0x2B,0x2C,0x2D,0x2E,EOT},
193 {0x85,0x12,0x22,0x01,NANA,0x00,0x00,NANA,NANA,NANA,
194 NANA,NANA,NANA,0x00,NANA,EOT}},
195 {0x4, "System Wake-Up",
196 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
197 {0x00,0x00,0x00,0x00,0x00,0x00,0x03,EOT}},
198 {0x5, "Mouse",
199 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
200 {0x00,0x00,0x00,0x00,0x00,0x0C,0x03,NANA,EOT}},
201 {0x6, "Keyboard",
202 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
203 {0x00,0x00,0x60,0x00,0x64,0x01,0x03,NANA,EOT}},
204 {0xf, "Shared Memory/Flash",
205 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf4,0xf5,
206 0xf6,EOT},
207 {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
208 0x00,EOT}},
209 {0x10, "BRAM",
210 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf3,0xf4,
211 0xf5,EOT},
212 {0x00,0x00,0x70,0x00,0x72,0x08,0x00,NANA,NANA,
213 NANA,EOT}},
214 {0x11, "Power Channel 1",
215 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
216 {0x00,0x00,0x62,0x00,0x66,0x01,0x03,EOT}},
217 {0x12, "Power Channel 2",
218 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
219 {0x00,0x00,0x68,0x00,0x6c,0x01,0x03,EOT}},
220 {EOT}}},
221 {0x8513, "IT8513E/F/G", {
222 {EOT}}},
223 {0x8516, "IT8516???", {
224 {NOLDN, "Chip ID",
225 {0x20,0x21, EOT},
226 {0x85,0x16, EOT}},
227 {NOLDN, "Chip Version",
228 {0x22,EOT},
229 {0x63,EOT}},
230 {NOLDN, "Super I/O Control Reigster (SIOCTRL)",
231 {0x23,EOT},
232 {0x01,EOT}},
233 {NOLDN, "Super I/O Configuration Register (SIOIRQ)",
234 {0x25,EOT},
235 {0x00,EOT}},
236 {NOLDN, "Super I/O General Purpose Register (SIOGP)",
237 {0x26,EOT},
238 {0x00,EOT}},
239 {NOLDN, "Super I/O Power Mode Register (SIOPWR)",
240 {0x2d,EOT},
241 {0x00,EOT}},
242 {0x01, "UART1",
243 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
244 {0x00,0x03,0xf8,0x00,0x00,0x04,0x02,EOT}},
245 {0x02, "UART2",
246 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
247 {0x00,0x02,0xf8,0x00,0x00,0x04,0x02,EOT}},
248 {0x04, "System Wakup-Up (SWUC)",
249 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
250 {0x00,0x00,0x00,0x00,0x00,0x00,0x01,EOT}},
251 {0x05, "Mouse",
252 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
253 {0x00,0x00,0x00,0x00,0x00,0x0C,0x01,EOT}},
254 {0x06, "Keyboard",
255 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
256 {0x00,0x00,0x60,0x00,0x64,0x01,0x01,EOT}},
257 {0x0f, "Shared Memory/Flash Interface (SMFI)",
258 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,
259 0xf4,0xf5,EOT},
260 {0x00,0x00,0x00,0x00,0x00,0x00,0x00,
261 NANA,NANA,EOT}},
262 {0x10, "BRAM / Real Time Clock (RTC)",
263 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,
264 0xf1,0xf2,0xf3,0xf4,0xf5,EOT},
265 {0x00,0x00,0x70,0x00,0x72,0x08,0x01,
266 NANA,NANA,NANA,NANA,NANA,EOT}},
267 {0x11, "Power Management Interface Channel 1",
268 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
269 {0x00,0x00,0x62,0x00,0x66,0x01,0x01,EOT}},
270 {0x12, "Power Management Interface Channel 2",
271 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
272 {0x00,0x00,0x68,0x00,0x6c,0x01,0x01,EOT}},
273 {0x17, "Power Management Interface Channel 3",
274 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
275 {0x00,0x00,0x6a,0x00,0x6e,0x01,0x01,EOT}},
276 {EOT}}},
277 {0x8528, "IT8528", {
278 {NOLDN, NULL,
279 {0x24,0x25,0x26,0x27,0x28,0x29,
280 0x2A,0x2B,0x2C,0x2D,0x2E,EOT},
281 {0x00,0x00,0x00,0x00,0x00,0x00,
282 0x00,0x00,0x01,0x00,0x00,EOT}},
283 {NOLDN, "Chip ID",
284 {0x20,0x21, EOT},
285 {0x85,0x28, EOT}},
286 {NOLDN, "Chip Version",
287 {0x22,EOT},
288 {0x0a,EOT}},
289 {NOLDN, "Super I/O Control Register (SIOCTRL)",
290 {0x23,EOT},
291 {0x01,EOT}},
292 {0x01, "UART1",
293 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
294 {0x00,0x03,0xf8,0x00,0x00,0x04,0x02,EOT}},
295 {0x02, "UART2",
296 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
297 {0x00,0x02,0xf8,0x00,0x00,0x03,0x02,EOT}},
298 {0x04, "System Wake-Up (SWUC)",
299 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
300 {0x00,0x00,0x00,0x00,0x00,0x00,0x01,EOT}},
301 {0x05, "Mouse",
302 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
303 {0x00,0x00,0x00,0x00,0x00,0x0C,0x01,EOT}},
304 {0x06, "Keyboard",
305 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
306 {0x00,0x00,0x60,0x00,0x64,0x01,0x01,EOT}},
307 {0x0f, "Shared Memory/Flash Interface (SMFI)",
308 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,
309 0xf4,0xf5,EOT},
310 {0x00,0x00,0x00,0x00,0x00,0x00,0x00,
311 NANA,NANA,EOT}},
312 {0x10, "BRAM / Real Time Clock (RTC)",
313 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,
314 0xf1,0xf2,0xf3,0xf4,0xf5,EOT},
315 {0x00,0x00,0x70,0x00,0x72,0x08,0x01,
316 NANA,NANA,NANA,NANA,NANA,EOT}},
317 {0x11, "Power Channel 1",
318 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
319 {0x00,0x00,0x62,0x00,0x66,0x01,0x01,EOT}},
320 {0x12, "Power Channel 2",
321 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
322 {0x00,0x00,0x68,0x00,0x6c,0x01,0x01,EOT}},
323 {0x17, "Power Channel 3",
324 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
325 {0x00,0x00,0x6a,0x00,0x6e,0x01,0x01,EOT}},
326 {0x18, "Power Channel 4",
327 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
328 {0x00,0x00,0x74,0x00,0x78,0x01,0x01,EOT}},
329 {0x19, "Power Channel 5",
330 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,EOT},
331 {0x00,0x00,0x7a,0x00,0x7c,0x01,0x01,EOT}},
332 {EOT}}},
333 {0x8613, "IT8613E", {
334 {NOLDN, NULL,
335 {0x20,0x21,0x22,0x23,0x24,0x2b,EOT},
336 {0x86,0x13,0x05,0x40,0x00,0x48,EOT}},
337 {0x1, "COM1",
338 {0x30,0x60,0x61,0x70,0xf0,EOT},
339 {0x00,0x03,0xf8,0x04,0x00,EOT}},
340 {0x4, "Environment controller",
341 {0x30,0x60,0x61,0x62,0x63,0x70,0xf0,0xf1,0xf2,0xf3,
342 0xf4,0xf5,0xf6,0xfa,0xfb,0xfc,EOT},
343 {0x00,0x02,0x90,0x02,0x30,0x09,0x00,0x00,0x00,0x00,
344 0x00,NANA,NANA,0x00,0x00,0x00,EOT}},
345 {0x5, "Keyboard",
346 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
347 {0x01,0x00,0x60,0x00,0x64,0x01,0x02,0x48,EOT}},
348 {0x6, "Mouse",
349 {0x30,0x70,0x71,0xf0,EOT},
350 {0x00,0x0c,0x02,0x00,EOT}},
351 {0x7, "GPIO",
352 {0x25,0x26,0x27,0x28,0x29,0x2a,0x2c,0x2d,0x60,0x61,
353 0x62,0x63,0x70,0x71,0x72,0x73,0x74,0xb0,0xb1,0xb2,
354 0xb3,0xb4,0xb8,0xba,0xbb,0xbc,0xbd,0xc0,0xc1,0xc2,
355 0xc3,0xc4,0xc8,0xc9,0xca,0xcb,0xcc,0xcd,0xda,0xdb,
356 0xe0,0xe1,0xe2,0xe3,0xe4,0xec,0xf0,0xf1,0xf2,0xf3,
357 0xf4,0xf5,0xf6,0xf7,0xf8,0xf9,0xfa,0xfb,EOT},
358 {0x00,0xF3,0x00,0x00,0x00,0x01,0x01,0x00,0x00,0x00,
359 0x00,0x00,0x00,0x00,0x20,0x38,0x00,0x00,0x00,0x00,
360 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,
361 0x40,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
362 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,NANA,NANA,
363 0x00,0x00,0x0e,0x00,0x00,0x00,0x00,0x00,EOT}},
364 {0xa, "Consumer IR",
365 {0x30,0x60,0x61,0x70,0xf0,EOT},
366 {0x00,0x03,0x10,0x0b,0x06,EOT}},
367 {EOT}}},
368 {0x8623, "IT8623E", {
369 /* Defaults are not specified as no datasheet available */
370 {NOLDN, NULL,
371 {0x20,0x21,0x22,0x23,0x24,0x2b,EOT},
372 {0x86,0x23,0x01,NANA,NANA,NANA,EOT}},
373 {0x0, "Floppy",
374 {0x30,0x60,0x61,0x70,0x74,0xf0,0xf1,EOT},
375 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
376 {0x1, "COM1",
377 {0x30,0x60,0x61,0x70,0xf0,0xf1,EOT},
378 {NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
379 {0x2, "COM2",
380 {0x30,0x60,0x61,0x70,0xf0,0xf1,EOT},
381 {NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
382 {0x3, "Parallel port",
383 {0x30,0x60,0x61,0x62,0x63,0x70,0x74,0xf0,EOT},
384 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
385 {0x4, "Environment controller",
386 {0x30,0x60,0x61,0x62,0x63,0x70,0xf0,0xf1,0xf2,0xf3,
387 0xf4,0xf5,0xf6,EOT},
388 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
389 NANA,NANA,NANA,EOT}},
390 {0x5, "Keyboard",
391 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
392 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
393 {0x6, "Mouse",
394 {0x30,0x70,0x71,0xf0,EOT},
395 {NANA,NANA,NANA,NANA,EOT}},
396 {0x7, "GPIO",
397 {0x25,0x26,0x27,0x28,0x29,0x2a,0x2c,0x60,0x61,0x62,
398 0x63,0x64,0x65,0x70,0x71,0x72,0x73,0x74,0xb0,0xb1,
399 0xb2,0xb3,0xb4,0xb5,0xb8,0xb9,0xba,0xbb,0xbc,0xbd,
400 0xc0,0xc1,0xc2,0xc3,0xc4,0xc8,0xc9,0xca,0xcb,0xcc,
401 0xe0,0xe1,0xe2,0xe3,0xe4,0xe5,0xe6,0xe7,0xe9,0xf0,
402 0xf1,0xf2,0xf3,0xf4,0xf5,0xf6,0xf7,0xf8,0xf9,0xfa,
403 0xfb,0xfc,0xfd,0xfe,0xff,EOT},
404 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
405 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
406 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
407 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
408 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
409 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
410 NANA,NANA,NANA,NANA,NANA,EOT}},
411 {EOT}}},
412 {0x8661, "IT8661F/IT8770F", {
413 {NOLDN, NULL,
414 {0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x20,0x21,0x22,
415 0x23,0x24,EOT},
416 {NANA,NANA,NANA,NANA,NANA,NANA,0x00,0x86,0x61,0x00,
417 0x00,0x00,EOT}},
418 {0x0, "Floppy",
419 {0x30,0x31,0x60,0x61,0x70,0x71,0x74,0xf0,EOT},
420 {0x00,0x00,0x03,0xf0,0x06,0x02,0x02,0x00,EOT}},
421 {0x1, "COM1",
422 {0x30,0x31,0x60,0x61,0x70,0x71,0xf0,EOT},
423 {0x00,0x00,0x03,0xf8,0x04,0x02,0x00,EOT}},
424 {0x2, "COM2",
425 {0x30,0x31,0x60,0x61,0x70,0x71,0xf0,EOT},
426 {0x00,0x00,0x02,0xf8,0x03,0x02,0x00,EOT}},
427 {0x3, "Parallel port",
428 {0x30,0x31,0x60,0x61,0x62,0x63,0x70,0x71,0x74,
429 0xf0,EOT},
430 {0x00,0x00,0x03,0x78,0x07,0x78,0x07,0x02,0x03,
431 0x03,EOT}},
432 {0x4, "IR",
433 {0x30,0x31,0x60,0x61,0x62,0x63,0x70,0x71,0x72,0x73,
434 0x74,0x75,0xf0,EOT},
435 {0x00,0x00,0x02,0xe8,0x03,0x00,0x0a,0x02,0x0b,0x02,
436 0x01,0x00,0x00,EOT}},
437 {0x5, "GPIO",
438 {0x25,0x26,0x60,0x61,0x62,0x63,0x64,0x65,0x66,0x67,
439 0x70,0xf0,0xf1,0xf2,0xf3,0xf4,0xf5,0xf6,0xf7,0xf8,
440 0xf9,0xfa,0xfb,0xfc,EOT},
441 {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
442 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
443 0x00,0x00,0x00,0x00,EOT}},
444 {EOT}}},
445 {0x8673, "IT8673F", {
446 {EOT}}},
447 {0x8681, "IT8671F/IT8687R", {
448 {NOLDN, NULL,
449 {0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x20,0x21,0x22,
450 0x23,0x24,0x25,0x26,0x2e,0x2f,EOT},
451 {NANA,NANA,NANA,NANA,NANA,NANA,0x00,0x86,0x81,0x00,
452 0x00,0x00,0x00,0x00,0x00,0x00,EOT}},
453 {0x0, "Floppy",
454 {0x30,0x31,0x60,0x61,0x70,0x71,0x74,0xf0,EOT},
455 {0x00,0x00,0x03,0xf0,0x06,0x02,0x02,0x00,EOT}},
456 {0x1, "COM1",
457 {0x30,0x31,0x60,0x61,0x70,0x71,0xf0,EOT},
458 {0x00,0x00,0x03,0xf8,0x04,0x02,0x00,EOT}},
459 {0x2, "COM2",
460 {0x30,0x31,0x60,0x61,0x62,0x63,0x70,0x71,0x72,0x73,
461 0x74,0x75,0xf0,0xf1,EOT},
462 {0x00,0x00,0x02,0xf8,0x03,0x00,0x03,0x02,0x0a,0x02,
463 0x00,0x01,0x00,0x00,EOT}},
464 {0x3, "Parallel port",
465 {0x30,0x31,0x60,0x61,0x62,0x63,0x70,0x71,0x74,
466 0xf0,EOT},
467 {0x00,0x00,0x03,0x78,0x07,0x78,0x07,0x02,0x03,
468 0x03,EOT}},
469 {0x4, "APC",
470 {0x30,0xf0,0xf1,0xf2,0xf4,0xf5,0xf6,EOT},
471 {0x00,0x00,0x00,0x00,0x00,0x00,0x00,EOT}},
472 {0x5, "Keyboard",
473 {0x30,0x31,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
474 {MISC,0x00,0x00,0x60,0x00,0x64,0x01,0x02,0x00,EOT}},
475 {0x6, "Mouse",
476 {0x30,0x70,0x71,0xf0,EOT},
477 {0x00,0x0c,0x02,0x00,EOT}},
478 {0x7, "GPIO",
479 {0x60,0x61,0x62,0x63,0x64,0x65,0x66,0x67,0x68,0x69,
480 0x70,0x71,0x72,0x73,0xf0,0xf1,0xf2,0xf3,0xf4,0xf5,
481 0xf6,0xf7,0xf8,0xf9,0xfa,0xfb,0xfc,0xfd,0xfe,0xff,
482 0xe0,0xe1,0xe2,0xe3,0xe4,EOT},
483 {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
484 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
485 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
486 0x00,0x00,0x00,0x00,0x00,EOT}},
487 {EOT}}},
488 {0x8701, "IT8703F", {
489 {NOLDN, NULL,
490 {0x20,0x21,0x23,0x24,0x26,0x29,0x2a,0x2b,EOT},
491 {0x87,0x00,0x00,0x80,0x00,0x00,0x7c,0xc0,EOT}},
492 {0x0, "Floppy",
493 {0x30,0x60,0x61,0x70,0x74,0xf0,0xf1,0xf2,0xf3,0xf4,
494 0xf5,EOT},
495 {0x00,0x03,0xf0,0x06,0x02,0x0e,0x00,0xff,0x00,0x00,
496 0x00,EOT}},
497 {0x1, "Parallel port",
498 {0x30,0x60,0x61,0x62,0x63,0x70,0x74,0xf0,EOT},
499 {0x00,0x03,0x78,0x00,0x80,0x07,0x03,0x03,EOT}},
500 {0x2, "COM1",
501 {0x30,0x60,0x61,0x70,0xf0,EOT},
502 {0x00,0x03,0xf8,0x04,0x00,EOT}},
503 {0x3, "COM2",
504 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,0xf3,EOT},
505 {0x00,0x02,0xf8,0x03,0x00,0x00,0x00,0x7f,EOT}},
506 {0x5, "Keyboard",
507 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
508 {0x01,0x00,0x60,0x00,0x64,0x01,0x0c,0x80,EOT}},
509 {0x6, "Consumer IR",
510 {0x30,0x60,0x61,0x70,EOT},
511 {0x00,0x00,0x00,0x00,EOT}},
512 {0x7, "Game port, MIDI, GPIO set 1",
513 {0x30,0x60,0x61,0x62,0x63,0x70,0xf0,0xf1,0xf2,EOT},
514 {0x00,0x02,0x01,0x03,0x30,0x00,0xff,0x00,0x00,EOT}},
515 {0x8, "GPIO set 2",
516 {0x30,0xf0,0xf1,0xf2,0xf3,0xf5,EOT},
517 {0x00,0xff,0x00,0x00,0x00,0x00,EOT}},
518 {0x9, "GPIO set 3 and 4",
519 {0x30,0x60,0x61,0xf0,0xf1,0xf2,0xf3,0xf4,EOT},
520 {0x00,0x02,0x90,0xff,0x00,0x00,0x00,0x00,EOT}},
521 {0xa, "ACPI",
522 {0x30,0x70,0xe0,0xe1,0xe2,0xe3,0xe4,0xe5,0xe6,0xe7,
523 0xf3,0xf4,0xf6,0xf7,0xf9,EOT},
524 {0x00,0x00,0x00,0x00,NANA,NANA,0x00,0x00,0x00,0x00,
525 NANA,NANA,0x00,0x00,0x00,EOT}},
526 {0xc, "GPIO set 5, 6 and 7",
527 {0x30,0x60,0x61,0xf0,0xf3,0xf6,EOT},
528 {0x00,0x03,0x70,0x00,0xff,0xff,EOT}},
529 {EOT}}},
530 {0x8702, "IT8702F", {
531 {EOT}}},
532 {0x8705, "IT8705F/AF / IT8700F", {
533 {NOLDN, NULL,
534 {0x20,0x21,0x22,0x23,0x24,EOT},
535 {0x87,0x05,0x00,0x00,NANA,EOT}},
536 {0x0, "Floppy",
537 {0x30,0x60,0x61,0x70,0x74,0xf0,0xf1,EOT},
538 {0x00,0x03,0xf0,0x06,0x02,0x00,0x00,EOT}},
539 {0x1, "COM1",
540 {0x30,0x60,0x61,0x70,0xf0,EOT},
541 {0x00,0x03,0xf8,0x04,0x00,EOT}},
542 {0x2, "COM2",
543 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,0xf3,EOT},
544 {0x00,0x02,0xf8,0x03,0x00,0x50,0x00,0x7f,EOT}},
545 {0x3, "Parallel port",
546 {0x30,0x60,0x61,0x62,0x63,0x64,0x65,0x70,0x74,
547 0xf0,EOT},
548 {0x00,0x03,0x78,0x07,0x78,0x00,0x80,0x07,0x03,
549 0x03,EOT}},
550 {0x4, "Environment controller",
551 {0x2b,0x30,0x60,0x61,0x62,0x63,0x70,0xf0,0xf1,0xf2,
552 0xf3,0xf4,0xf5,0xf6,EOT},
553 {0x00,0x00,0x02,0x90,0x02,0x30,0x09,0x00,0x00,0x00,
554 0x00,0x00,NANA,NANA,EOT}},
555 {0x5, "GPIO",
556 {0x25,0x26,0x27,0x28,0x29,0x2a,0x60,0x61,0x62,0x63,
557 0x64,0x65,0x70,0x71,0x72,0xb0,0xb1,0xb2,0xb3,0xb4,
558 0xb5,0xb8,0xb9,0xba,0xbb,0xbc,0xbd,0xc0,0xc1,0xc2,
559 0xc3,0xc4,0xc5,0xc8,0xc9,0xca,0xcb,0xcc,0xcd,0xd0,
560 0xd1,0xd2,0xd3,0xd4,0xd5,0xd6,0xd8,0xd9,0xda,0xf0,
561 0xf1,0xf2,0xf5,0xf6,0xf7,0xf8,0xf9,0xfa,0xfb,0xfc,
562 0xfd,0xfe,0xff,EOT},
563 {0x00,0x00,0x00,0xff,0xe0,0xff,0x00,0x00,0x00,0x00,
564 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
565 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
566 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
567 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
568 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
569 0x00,NANA,0x00,EOT}},
570 {0x6, "Game port",
571 {0x30,0x60,0x61,EOT},
572 {0x00,0x02,0x01,EOT}},
573 {0x7, "Consumer IR",
574 {0x30,0x60,0x61,0x70,0xf0,EOT},
575 {0x00,0x03,0x10,0x0b,0x00,EOT}},
576 {0x8, "MIDI port",
577 {0x30,0x60,0x61,0x70,0xf0,EOT},
578 {0x00,0x03,0x00,0x0a,0x00,EOT}},
579 {EOT}}},
580 {0x8706, "IT8706R", { /* TODO: Not yet in sensors-detect */
581 /* This is a "Special General Purpose I/O chip". */
582 {EOT}}},
583 {0x8707, "IT8707F", {
584 {EOT}}},
585 {0x8708, "IT8708F", {
586 {NOLDN, NULL,
587 {0x20,0x21,0x22,0x23,0x24,0x25,0x26,0x27,0x28,0x29,
588 0x2a,0x2e,0x2f,EOT},
589 {0x87,0x08,0x00,0x00,NANA,0x3f,0x00,0xff,0xff,0xff,
590 0xff,0x00,0x00,EOT}},
591 {0x0, "Floppy",
592 {0x30,0x60,0x61,0x70,0x74,0xf0,0xf1,EOT},
593 {0x00,0x03,0xf0,0x06,0x02,0x00,0x00,EOT}},
594 {0x1, "COM1",
595 {0x30,0x60,0x61,0x70,0xf0,EOT},
596 {0x00,0x03,0xf8,0x04,0x00,EOT}},
597 {0x2, "COM2",
598 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,0xf3,EOT},
599 {0x00,0x02,0xf8,0x03,0x00,0x50,0x00,0x7f,EOT}},
600 {0x3, "Parallel port",
601 {0x30,0x60,0x61,0x62,0x63,0x64,0x65,0x70,0x74,
602 0xf0,EOT},
603 {0x00,0x03,0x78,0x07,0x78,0x00,0x80,0x07,0x03,
604 0x03,EOT}},
605 {0x4, "SWC",
606 {0xe0,0xe1,0xe2,0xe3,0xe4,0xe5,0xe6,0xe7,
607 0xf0,0xf1,0xf2,0xf3,0xf4,0xf5,0xf6,EOT},
608 {NANA,NANA,0x00,0x00,0x00,0x00,0x00,0x00,
609 0x00,0x00,0x00,0x00,0x00,NANA,NANA,EOT}},
610 {0x5, "Keyboard",
611 /* Note: 0x30 can actually be 0x00 _or_ 0x01. */
612 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
613 {0x01,0x00,0x60,0x00,0x64,0x01,0x02,0x00,EOT}},
614 {0x6, "Mouse",
615 {0x30,0x70,0x71,0xf0,EOT},
616 {0x00,0x0c,0x02,0x00,EOT}},
617 {0x7, "GPIO",
618 {0x70,0xb0,0xb1,0xb2,0xb3,0xb4,0xb5,0xb8,0xb9,0xba,
619 0xbb,0xbc,0xbd,0xc0,0xc1,0xc2,0xc3,0xc4,0xc5,0xc8,
620 0xc9,0xca,0xcb,0xcc,0xcd,0xd0,0xd1,0xd2,0xd3,0xd4,
621 0xd5,0xd6,0xd7,0xd8,0xd9,0xda,0xdb,0xdc,0xf0,0xf1,
622 0xf2,0xf3,0xf4,0xf5,0xf6,0xf7,0xf8,0xf9,0xfa,0xfb,
623 0xfc,EOT},
624 {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
625 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
626 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
627 0x00,0x00,NANA,NANA,NANA,NANA,NANA,NANA,0x00,0x00,
628 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,NANA,
629 0x00,EOT}},
630 {0x8, "Game port",
631 {0x30,0x60,0x61,EOT},
632 {0x00,0x02,0x01,EOT}},
633 {0x9, "Consumer IR",
634 {0x30,0x60,0x61,0x70,0xf0,EOT},
635 {0x00,0x03,0x10,0x0b,0x00,EOT}},
636 {0xa, "MIDI port",
637 {0x30,0x60,0x61,0x70,0xf0,EOT},
638 {0x00,0x03,0x00,0x0a,0x00,EOT}},
639 {EOT}}},
640 {0x8710, "IT8710F", { /* TODO: Not yet in sensors-detect */
641 {EOT}}},
642 {0x8711, "IT8711F", { /* 0x8711 is a guess, not found in datasheet. */
643 {EOT}}},
644 {0x8712, "IT8712F", {
645 {NOLDN, NULL,
646 {0x20,0x21,0x22,0x23,0x24,0x2b,EOT},
647 {0x87,0x12,0x08,0x00,0x00,0x00,EOT}},
648 {0x0, "Floppy",
649 {0x30,0x60,0x61,0x70,0x74,0xf0,0xf1,EOT},
650 {0x00,0x03,0xf0,0x06,0x02,0x00,0x00,EOT}},
651 {0x1, "COM1",
652 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,0xf3,EOT},
653 {0x00,0x03,0xf8,0x04,0x00,0x50,0x00,0x7f,EOT}},
654 {0x2, "COM2",
655 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,0xf3,EOT},
656 {0x00,0x02,0xf8,0x03,0x00,0x50,0x00,0x7f,EOT}},
657 {0x3, "Parallel port",
658 {0x30,0x60,0x61,0x62,0x63,0x70,0x74,0xf0,EOT},
659 {0x00,0x03,0x78,0x07,0x78,0x07,0x03,0x03,EOT}},
660 {0x4, "Environment controller",
661 {0x30,0x60,0x61,0x62,0x63,0x70,0xf0,0xf1,0xf2,0xf3,
662 0xf4,0xf5,0xf6,EOT},
663 {0x00,0x02,0x90,0x02,0x30,0x09,0x00,0x00,0x00,0x00,
664 0x00,NANA,NANA,EOT}},
665 {0x5, "Keyboard",
666 /* TODO: 0xf0: Error in datasheet? */
667 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
668 {0x01,0x00,0x60,0x00,0x64,0x01,0x02,0x08,EOT}},
669 {0x6, "Mouse",
670 {0x30,0x70,0x71,0xf0,EOT},
671 {0x00,0x0c,0x02,0x00,EOT}},
672 {0x7, "GPIO", /* TODO: 0x72, 0x73: Errors in datasheet? */
673 {0x25,0x26,0x27,0x28,0x29,0x2a,0x2c,0x60,0x61,0x62,
674 0x63,0x64,0x65,0x70,0x71,0x72,0x73,0x74,0xb0,0xb1,
675 0xb2,0xb3,0xb4,0xb5,0xb8,0xb9,0xba,0xbb,0xbc,0xbd,
676 0xc0,0xc1,0xc2,0xc3,0xc4,0xc8,0xc9,0xca,0xcb,0xcc,
677 0xe0,0xe1,0xe2,0xe3,0xe4,0xf0,0xf1,0xf2,0xf3,0xf4,
678 0xf5,0xf6,0xf7,0xf8,0xf9,0xfa,0xfb,0xfc,0xfd,EOT},
679 {0x01,0x00,0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,
680 0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x00,0x00,0x00,
681 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
682 0x01,0x00,0x00,0x40,0x00,0x01,0x00,0x00,0x40,0x00,
683 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
684 0x00,0x00,0x00,0x00,0x00,0x00,0x00,NANA,0x00,EOT}},
685 {0x8, "MIDI port",
686 {0x30,0x60,0x61,0x70,0xf0,EOT},
687 {0x00,0x03,0x00,0x0a,0x00,EOT}},
688 {0x9, "Game port",
689 {0x30,0x60,0x61,EOT},
690 {0x00,0x02,0x01,EOT}},
691 {0xa, "Consumer IR",
692 {0x30,0x60,0x61,0x70,0xf0,EOT},
693 {0x00,0x03,0x10,0x0b,0x00,EOT}},
694 {EOT}}},
695 {0x8716, "IT8716F", {
696 {NOLDN, NULL,
697 {0x20,0x21,0x22,0x23,0x24,0x2b,EOT},
698 {0x87,0x16,0x01,0x00,0x00,0x00,EOT}},
699 {0x0, "Floppy",
700 {0x30,0x60,0x61,0x70,0x74,0xf0,0xf1,EOT},
701 {0x00,0x03,0xf0,0x06,0x02,0x00,0x00,EOT}},
702 {0x1, "COM1",
703 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,0xf3,EOT},
704 {0x00,0x03,0xf8,0x04,0x00,0x50,0x00,0x7f,EOT}},
705 {0x2, "COM2",
706 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,0xf3,EOT},
707 {0x00,0x02,0xf8,0x03,0x00,0x50,0x00,0x7f,EOT}},
708 {0x3, "Parallel port",
709 {0x30,0x60,0x61,0x62,0x63,0x70,0x74,0xf0,EOT},
710 {0x00,0x03,0x78,0x07,0x78,0x07,0x03,0x03,EOT}},
711 {0x4, "Environment controller",
712 {0x30,0x60,0x61,0x62,0x63,0x70,0xf0,0xf1,0xf2,0xf3,
713 0xf4,0xf5,0xf6,EOT},
714 {0x00,0x02,0x90,0x02,0x30,0x09,0x00,0x00,0x00,0x00,
715 0x00,NANA,NANA,EOT}},
716 {0x5, "Keyboard",
717 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
718 {0x01,0x00,0x60,0x00,0x64,0x01,0x02,0x00,EOT}},
719 {0x6, "Mouse",
720 {0x30,0x70,0x71,0xf0,EOT},
721 {0x00,0x0c,0x02,0x00,EOT}},
722 {0x7, "GPIO",
723 {0x25,0x26,0x27,0x28,0x29,0x2a,0x2c,0x60,0x61,0x62,
724 0x63,0x64,0x65,0x70,0x71,0x72,0x73,0x74,0xb0,0xb1,
725 0xb2,0xb3,0xb4,0xb5,0xb8,0xb9,0xba,0xbb,0xbc,0xbd,
726 0xc0,0xc1,0xc2,0xc3,0xc4,0xc8,0xc9,0xca,0xcb,0xcc,
727 0xe0,0xe1,0xe2,0xe3,0xe4,0xf0,0xf1,0xf2,0xf3,0xf4,
728 0xf5,0xf6,0xf7,0xf8,0xf9,0xfa,0xfb,0xfc,0xfd,EOT},
729 {0x01,0x00,0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,
730 0x00,0x00,0x00,0x00,0x00,0x20,0x38,0x00,0x00,0x00,
731 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
732 0x01,0x00,0x00,0x40,0x00,0x01,0x00,0x00,0x40,0x00,
733 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
734 0x00,0x00,0x00,0x00,0x00,0x00,0x00,NANA,0x00,EOT}},
735 {0x8, "MIDI port",
736 {0x30,0x60,0x61,0x70,0xf0,EOT},
737 {0x00,0x03,0x00,0x0a,0x00,EOT}},
738 {0x9, "Game port",
739 {0x30,0x60,0x61,EOT},
740 {0x00,0x02,0x01,EOT}},
741 {0xa, "Consumer IR",
742 {0x30,0x60,0x61,0x70,0xf0,EOT},
743 {0x00,0x03,0x10,0x0b,0x00,EOT}},
744 {EOT}}},
745 {0x8718, "IT8718F", {
746 {NOLDN, NULL,
747 {0x20,0x21,0x22,0x23,0x24,0x2b,EOT},
748 {0x87,0x18,0x01,0x00,0x00,0x00,EOT}},
749 {0x0, "Floppy",
750 {0x30,0x60,0x61,0x70,0x74,0xf0,0xf1,EOT},
751 {0x00,0x03,0xf0,0x06,0x02,0x00,0x00,EOT}},
752 {0x1, "COM1",
753 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,0xf3,EOT},
754 {0x00,0x03,0xf8,0x04,0x00,0x50,0x00,0x7f,EOT}},
755 {0x2, "COM2",
756 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,0xf3,EOT},
757 {0x00,0x02,0xf8,0x03,0x00,0x50,0x00,0x7f,EOT}},
758 {0x3, "Parallel port",
759 {0x30,0x60,0x61,0x62,0x63,0x70,0x74,0xf0,EOT},
760 {0x00,0x03,0x78,0x07,0x78,0x07,0x03,0x03,EOT}},
761 {0x4, "Environment controller",
762 {0x30,0x60,0x61,0x62,0x63,0x70,0xf0,0xf1,0xf2,0xf3,
763 0xf4,0xf5,0xf6,EOT},
764 {0x00,0x02,0x90,0x02,0x30,0x09,0x00,0x00,0x00,0x00,
765 0x00,NANA,NANA,EOT}},
766 {0x5, "Keyboard",
767 /* 0xf0: Datasheet page 33: 0x00; page 56: 0x08. */
768 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
769 {0x01,0x00,0x60,0x00,0x64,0x01,0x02,0x00,EOT}},
770 {0x6, "Mouse",
771 {0x30,0x70,0x71,0xf0,EOT},
772 {0x00,0x0c,0x02,0x00,EOT}},
773 {0x7, "GPIO",
774 /* 0x2c: Datasheet page 30: 0x00; page 43: 0x1f. */
775 {0x25,0x26,0x27,0x28,0x29,0x2a,0x2c,0x60,0x61,0x62,
776 0x63,0x64,0x65,0x70,0x71,0x72,0x73,0x74,0xb0,0xb1,
777 0xb2,0xb3,0xb4,0xb5,0xb8,0xb9,0xba,0xbb,0xbc,0xbd,
778 0xc0,0xc1,0xc2,0xc3,0xc4,0xc5,0xc8,0xc9,0xca,0xcb,
779 0xcc,0xe0,0xe1,0xe2,0xe3,0xe4,0xe5,0xe6,0xe7,0xf0,
780 0xf1,0xf2,0xf3,0xf4,0xf5,0xf6,0xf7,0xf8,0xf9,0xfa,
781 0xfb,0xfc,0xfd,0xfe,0xff,EOT},
782 {0x01,0x00,0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,
783 0x00,0x00,0x00,0x00,0x00,0x20,0x38,0x00,0x00,0x00,
784 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
785 0x01,0x00,0x00,0x40,0x00,0x00,0x01,0x00,0x00,0x40,
786 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
787 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
788 0x00,NANA,0x00,0x00,0x00,EOT}},
789 {0xa, "Consumer IR",
790 {0x30,0x60,0x61,0x70,0xf0,EOT},
791 {0x00,0x03,0x10,0x0b,0x00,EOT}},
792 {EOT}}},
793 {0x8720, "IT8720F", {
794 {NOLDN, NULL,
795 {0x20,0x21,0x22,0x23,0x24,0x2b,EOT},
796 {0x87,0x20,0x05,0x00,0x00,0x00,EOT}},
797 {0x0, "Floppy",
798 {0x30,0x60,0x61,0x70,0x74,0xf0,0xf1,EOT},
799 {0x00,0x03,0xf0,0x06,0x02,0x00,0x00,EOT}},
800 {0x1, "COM1",
801 {0x30,0x60,0x61,0x70,0xf0,0xf1,EOT},
802 {0x00,0x03,0xf8,0x04,0x00,0x50,EOT}},
803 {0x2, "COM2",
804 {0x30,0x60,0x61,0x70,0xf0,0xf1,EOT},
805 {0x00,0x02,0xf8,0x03,0x00,0x50,EOT}},
806 {0x3, "Parallel port",
807 {0x30,0x60,0x61,0x62,0x63,0x70,0x74,0xf0,EOT},
808 {0x00,0x03,0x78,0x07,0x78,0x07,0x03,0x03,EOT}},
809 {0x4, "Environment controller",
810 {0x30,0x60,0x61,0x62,0x63,0x70,0xf0,0xf1,0xf2,0xf3,
811 0xf4,0xf5,0xf6,EOT},
812 {0x00,0x02,0x90,0x02,0x30,0x09,0x00,0x00,0x00,0x00,
813 0x00,NANA,NANA,EOT}},
814 {0x5, "Keyboard",
815 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
816 {0x01,0x00,0x60,0x00,0x64,0x01,0x02,0x48,EOT}},
817 {0x6, "Mouse",
818 {0x30,0x70,0x71,0xf0,EOT},
819 {0x00,0x0c,0x02,0x00,EOT}},
820 {0x7, "GPIO",
821 {0x25,0x26,0x27,0x28,0x29,0x2a,0x2c,0x60,0x61,0x62,
822 0x63,0x64,0x65,0x70,0x71,0x72,0x73,0x74,0xb0,0xb1,
823 0xb2,0xb3,0xb4,0xb5,0xb8,0xb9,0xba,0xbb,0xbc,0xbd,
824 0xc0,0xc1,0xc2,0xc3,0xc4,0xc8,0xc9,0xca,0xcb,0xcc,
825 0xe0,0xe1,0xe2,0xe3,0xe4,0xe5,0xe6,0xe7,0xe9,0xf0,
826 0xf1,0xf2,0xf3,0xf4,0xf5,0xf6,0xf7,0xf8,0xf9,0xfa,
827 0xfb,0xfc,0xfd,0xfe,0xff,EOT},
828 {0x00,0xff,0x00,0x40,0x00,0x00,0x03,0x00,0x00,0x00,
829 0x00,0x00,0x00,0x00,0x00,NANA,0x38,0x00,0x00,0x00,
830 0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00,
831 0x01,0x00,0x00,0x40,0x00,0x01,0x00,0x00,0x40,0x00,
832 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,NANA,0x00,
833 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
834 0x00,NANA,0x00,0x00,0x00,EOT}},
835 {0xa, "Consumer IR",
836 {0x30,0x60,0x61,0x70,0xf0,EOT},
837 {0x00,0x03,0x10,0x0b,0x06,EOT}},
838 {EOT}}},
839 {0x8721, "IT8721F", {
840 {EOT}}},
841 {0x8722, "IT8722F", {
842 {EOT}}},
843 {0x8726, "IT8726F", {
844 /* Datasheet wrongly says that the ID is 0x8716. */
845 {NOLDN, NULL,
846 {0x20,0x21,0x22,0x23,0x24,0x2b,EOT},
847 {0x87,0x26,0x01,0x00,MISC,0x00,EOT}},
848 {0x0, "Floppy",
849 {0x30,0x60,0x61,0x70,0x74,0xf0,0xf1,EOT},
850 {0x00,0x03,0xf0,0x06,0x02,0x00,0x00,EOT}},
851 {0x1, "COM1",
852 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,0xf3,EOT},
853 {0x00,0x03,0xf8,0x04,0x00,0x50,0x00,0x7f,EOT}},
854 {0x2, "COM2",
855 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,0xf3,EOT},
856 {0x00,0x02,0xf8,0x03,0x00,0x50,0x00,0x7f,EOT}},
857 {0x3, "Parallel port",
858 {0x30,0x60,0x61,0x62,0x63,0x70,0x74,0xf0,EOT},
859 {0x00,0x03,0x78,0x07,0x78,0x07,0x03,0x03,EOT}},
860 {0x4, "Environment controller",
861 {0x30,0x60,0x61,0x62,0x63,0x70,0xf0,0xf1,0xf2,0xf3,
862 0xf4,0xf5,0xf6,EOT},
863 {0x00,0x02,0x90,0x02,0x30,0x09,0x00,0x00,0x00,0x00,
864 0x00,MISC,MISC,EOT}},
865 {0x5, "Keyboard",
866 /* 0xf0: Datasheet page 35: 0x00; page 59: 0x08. */
867 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
868 {0x01,0x00,0x60,0x00,0x64,0x01,0x02,0x08,EOT}},
869 {0x6, "Mouse",
870 {0x30,0x70,0x71,0xf0,EOT},
871 {0x00,0x0c,0x02,0x00,EOT}},
872 {0x7, "GPIO",
873 /* 0x2c: Datasheet page 33: 0x00; page 45: 0x1f. */
874 {0x25,0x26,0x27,0x28,0x29,0x2a,0x2c,0x60,0x61,0x62,
875 0x63,0x64,0x65,0x70,0x71,0x72,0x73,0x74,0xb0,0xb1,
876 0xb2,0xb3,0xb4,0xb5,0xb8,0xb9,0xba,0xbb,0xbc,0xbd,
877 0xc0,0xc1,0xc2,0xc3,0xc4,0xc8,0xc9,0xca,0xcb,0xcc,
878 0xe0,0xe1,0xe2,0xe3,0xe4,0xf0,0xf1,0xf2,0xf3,0xf4,
879 0xf5,0xf6,0xf7,0xf8,0xf9,0xfa,0xfb,0xfc,0xfd,EOT},
880 {0x01,0x00,0x00,0x40,0x00,0x00,0x1f,0x00,0x00,0x00,
881 0x00,0x00,0x00,0x00,0x00,MISC,0x38,0x00,0x00,0x00,
882 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
883 0x01,0x00,0x00,0x40,0x00,0x01,0x00,0x00,0x40,0x00,
884 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
885 0x00,0x00,0x00,0x00,0x00,0x00,0x00,MISC,0x00,EOT}},
886 {0x8, "MIDI port",
887 {0x30,0x60,0x61,0x70,0xf0,EOT},
888 {0x00,0x03,0x00,0x0a,0x00,EOT}},
889 {0x9, "Game port",
890 {0x30,0x60,0x61,EOT},
891 {0x00,0x02,0x01,EOT}},
892 {0xa, "Consumer IR",
893 {0x30,0x60,0x61,0x70,0xf0,EOT},
894 {0x00,0x03,0x10,0x0b,0x00,EOT}},
895 {EOT}}},
896 {0x8728, "IT8728F", {
897 {NOLDN, NULL,
898 {0x02,0x07,0x20,0x21,0x22,0x23,0x24,0x2b,0x2e,0x2f,EOT},
899 {NANA,NANA,0x87,0x28,0x01,0x00,0x00,MISC,0x00,0x00,EOT}},
900 {0x0, "Floppy",
901 {0x30,0x60,0x61,0x70,0x74,0xf0,0xf1,EOT},
902 {0x00,0x03,0xf0,0x06,0x02,0x00,0x00,EOT}},
903 {0x1, "COM1",
904 {0x30,0x60,0x61,0x70,0xf0,0xf1,EOT},
905 {0x00,0x03,0xf8,0x04,0x00,0x50,EOT}},
906 {0x2, "COM2",
907 {0x30,0x60,0x61,0x70,0xf0,0xf1,EOT},
908 {0x00,0x02,0xf8,0x03,0x00,0x50,EOT}},
909 {0x3, "Parallel port",
910 {0x30,0x60,0x61,0x62,0x63,0x70,0x74,0xf0,EOT},
911 {0x00,0x03,0x78,0x07,0x78,0x07,0x03,0x03,EOT}},
912 {0x4, "Environment controller",
913 {0x30,0x60,0x61,0x62,0x63,0x70,0xf0,0xf1,0xf2,
914 0xf3,0xf4,0xf5,0xf6,0xF9,0xFA,0xFB,EOT},
915 {0x00,0x02,0x90,0x02,0x30,0x09,0x00,0x00,0x00,
916 0x00,0x00,MISC,MISC,MISC,MISC,MISC,EOT}},
917 {0x5, "Keyboard",
918 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
919 {0x01,0x00,0x60,0x00,0x64,0x01,0x02,0x48,EOT}},
920 {0x6, "Mouse",
921 {0x30,0x70,0x71,0xf0,EOT},
922 {0x00,0x0c,0x02,0x00,EOT}},
923 {0x7, "GPIO",
924 {0x25,0x26,0x27,0x28,0x29,0x2a,0x2c,0x2d,0x60,
925 0x61,0x62,0x63,0x64,0x65,0x70,0x71,0x72,0x73,
926 0x74,0xb0,0xb1,0xb2,0xb3,0xb4,0xb8,0xb9,0xba,
927 0xbb,0xbc,0xbd,0xc0,0xc1,0xc2,0xc3,0xc4,0xc8,
928 0xc9,0xca,0xcb,0xcc,0xcd,0xce,0xcf,0xe0,0xe1,
929 0xe2,0xe3,0xe4,0xe9,0xf0,0xf1,0xf2,0xf3,0xf4,
930 0xf5,0xf6,0xf7,0xf8,0xf9,0xfa,0xfb,EOT},
931 {0x00,0xf3,0x00,0x00,0x00,0x00,0x03,0x00,0x00,
932 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x38,
933 0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00,
934 0x00,0x00,0x00,0x01,0x00,0x00,0x40,0x00,0x01,
935 0x00,0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,
936 0x00,0x00,0x00,MISC,0x00,0x00,0x00,0x00,0x00,
937 0x00,0x00,0x00,0x00,0x00,0x00,0x00,EOT}},
938 {0xa, "Consumer IR",
939 {0x30,0x60,0x61,0x70,0xf0,EOT},
940 {0x00,0x03,0x10,0x0b,0x06,EOT}},
941 {EOT}}},
942 {0x8761, "IT8761E", {
943 {EOT}}},
944 {0x8772, "IT8772F", {
945 {EOT}}},
946 {0x8780, "IT8780F", {
947 {EOT}}},
948 {0x8783, "IT8783E/F", {
949 {NOLDN, NULL,
950 {0x02,0x07,0x20,0x21,0x22,0x23,0x24,0x25,0x26,
951 0x27,0x28,0x29,0x2a,0x2b,0x2c,0x2d,0x2e,0x2f,
952 EOT},
953 {NANA,NANA,0x87,0x83,0x00,0x00,MISC,0x00,0x00,
954 0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x00,0x00,
955 EOT}},
956 {0x0, "Floppy",
957 {0x30,0x60,0x61,0x70,0x74,0xf0,0xf1,EOT},
958 {0x00,0x03,0xf0,0x06,0x02,0x00,0x00,EOT}},
959 {0x1, "COM1",
960 {0x30,0x60,0x61,0x70,0xf0,EOT},
961 {0x00,0x03,0xf8,0x04,0x00,EOT}},
962 {0x2, "COM2",
963 {0x30,0x60,0x61,0x70,0xf0,EOT},
964 {0x00,0x02,0xf8,0x03,0x00,EOT}},
965 {0x3, "Parallel port",
966 {0x30,0x60,0x61,0x62,0x63,0x70,0x74,0xf0,EOT},
967 {0x00,0x03,0x78,0x07,0x78,0x07,0x03,0x03,EOT}},
968 {0x4, "Environment controller",
969 {0x30,0x60,0x61,0x62,0x63,0x70,0xf0,0xf1,0xf2,
970 0xf3,0xf4,0xf5,0xf6,0xf7,EOT},
971 {0x00,0x02,0x90,0x02,0x30,0x09,0x00,0x00,0x00,
972 0x00,0x00,MISC,MISC,MISC,EOT}},
973 {0x5, "Keyboard",
974 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
975 {0x01,0x00,0x60,0x00,0x64,0x01,0x02,0x08,EOT}},
976 {0x6, "Mouse",
977 {0x30,0x70,0x71,0xf0,EOT},
978 {0x00,0x0c,0x02,0x00,EOT}},
979 {0x7, "GPIO",
980 {0x60,0x61,0x62,0x63,0x64,0x65,0x70,0x71,0x72,
981 0x73,0x74,0x81,0x82,0x83,0x84,0x91,0x92,0x93,
982 0x94,0xb0,0xb1,0xb2,0xb3,0xb4,0xb8,0xb9,0xba,
983 0xbb,0xbc,0xc0,0xc1,0xc2,0xc3,0xc4,0xc8,0xc9,
984 0xca,0xcb,0xcc,0xcd,0xe0,0xe1,0xe2,0xe3,0xe4,
985 0xef,0xf0,0xf1,0xf2,0xf3,0xf4,0xf5,0xf6,0xf7,
986 0xf8,0xf9,0xfa,0xfb,EOT},
987 {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,MISC,
988 0x38,0x00,0x00,MISC,0x38,0x00,0x00,MISC,0x38,
989 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
990 0x00,0x00,0x01,0x00,0x00,0x40,0x00,0x01,0x00,
991 0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
992 MISC,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
993 0x00,0x00,0x00,0x00,EOT}},
994 {0x8, "COM3",
995 {0x30,0x60,0x61,0x70,0xf0,EOT},
996 {0x00,0x03,0xf8,0x04,0x00,EOT}},
997 {0x9, "COM4",
998 {0x30,0x60,0x61,0x70,0xf0,EOT},
999 {0x00,0x02,0xf8,0x03,0x00,EOT}},
1000 {0xa, "COM5",
1001 {0x30,0x60,0x61,0x70,0xf0,EOT},
1002 {0x00,0x03,0xf8,0x04,0x00,EOT}},
1003 {0xb, "COM6",
1004 {0x30,0x60,0x61,0x70,0xf0,EOT},
1005 {0x00,0x02,0xf8,0x03,0x00,EOT}},
1006 {0xc, "Consumer IR",
1007 {0x30,0x60,0x61,0x70,0xf0,EOT},
1008 {0x00,0x03,0x10,0x0b,0x06,EOT}},
1009 {EOT}}},
1010 {0x8786, "IT8786E-I", {
1011 {NOLDN, NULL,
1012 {0x02,0x07,0x20,0x21,0x22,0x23,0x24,0x25,0x26,
1013 0x27,0x28,0x29,0x2a,0x2b,0x2c,0x2d,0x2e,0x2f,
1014 EOT},
1015 {NANA,NANA,0x87,0x86,0x03,0x40,RSVD,0x00,0xf3,
1016 0x00,0x00,0x00,0x00,0x48,0x89,0x00,0x00,0x00,
1017 EOT}},
1018 {0x1, "COM1",
1019 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,EOT},
1020 {0x00,0x03,0xf8,0x04,0x00,0x50,0x00,EOT}},
1021 {0x2, "COM2",
1022 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,EOT},
1023 {0x00,0x02,0xf8,0x03,0x00,0x50,0x00,EOT}},
1024 {0x3, "Parallel port",
1025 {0x30,0x60,0x61,0x62,0x63,0x70,0x74,0xf0,EOT},
1026 {0x00,0x03,0x78,0x07,0x78,0x07,0x03,0x03,EOT}},
1027 {0x4, "Environment controller",
1028 {0x30,0x60,0x61,0x62,0x63,0x70,0xf0,0xf1,0xf2,
1029 0xf3,0xf4,0xf5,0xf6,0xfa,0xfb,0xfc,EOT},
1030 {0x00,0x02,0x90,0x02,0x30,0x09,0x00,0x00,0x00,
1031 0x00,0x00,MISC,MISC,MISC,MISC,MISC,EOT}},
1032 {0x5, "Keyboard",
1033 {0x30,0x60,0x61,0x62,0x63,0x70,0x71,0xf0,EOT},
1034 {0x01,0x00,0x60,0x00,0x64,0x01,0x02,0x48,EOT}},
1035 {0x6, "Mouse",
1036 {0x30,0x70,0x71,0xf0,EOT},
1037 {0x00,0x0c,0x02,0x00,EOT}},
1038 {0x7, "GPIO",
1039 {0x60,0x61,0x62,0x63,0x70,0x71,0x72,0x73,0x74,0xb0,
1040 0xb1,0xb2,0xb3,0xb4,0xb8,0xb9,0xba,0xbb,0xbc,0xbd,
1041 0xc0,0xc1,0xc2,0xc3,0xc4,0xc8,0xc9,0xca,0xcb,0xcc,
1042 0xcd,0xce,0xcf,0xd1,0xd2,0xd3,0xd4,0xd6,0xd7,0xd8,
1043 0xd9,0xe0,0xe1,0xe2,0xe3,0xe4,0xf0,0xf1,0xf2,0xf3,
1044 0xf4,0xf5,0xf6,0xf7,0xf8,0xf9,0xfa,0xfb,EOT},
1045 {0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x38,0x00,0x00,
1046 0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00,
1047 0x01,0x00,0x00,0x40,0x00,0x01,0x00,0x00,0x40,0x00,
1048 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
1049 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
1050 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,EOT}},
1051 {0x8, "COM3",
1052 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,EOT},
1053 {0x00,0x03,0xf8,0x0b,0x00,0x50,0x00,EOT}},
1054 {0x9, "COM4",
1055 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,EOT},
1056 {0x00,0x02,0xf8,0x0a,0x00,0x50,0x00,EOT}},
1057 {0xa, "Consumer IR",
1058 {0x30,0x60,0x61,0x70,0xf0,EOT},
1059 {0x00,0x03,0x10,0x0b,0x06,EOT}},
1060 {0xb, "COM5",
1061 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,EOT},
1062 {0x00,0x03,0xf8,0x04,0x00,0x50,0x00,EOT}},
1063 {0xc, "COM6",
1064 {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,EOT},
1065 {0x00,0x02,0xf8,0x03,0x00,0x50,0x00,EOT}},
1066 {EOT}}},
1067 {EOT}
1070 static const struct superio_registers ec_table[] = {
1071 {0x8613, "IT8613E", {
1072 {NOLDN, NULL,
1073 {0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07,0x08,0x09,
1074 0x0a,0x0b,0x0c,0x0e,0x0f,0x11,0x12,0x13,0x14,0x16,
1075 0x17,0x19,0x1a,0x1c,0x1d,0x1e,0x1f,0x20,0x21,0x22,
1076 0x24,0x25,0x27,0x28,0x29,0x2a,0x2b,0x2c,0x2d,0x2e,
1077 0x2f,0x30,0x31,0x32,0x33,0x34,0x35,0x38,0x39,0x3a,
1078 0x3b,0x40,0x41,0x42,0x43,0x44,0x45,0x46,0x47,0x50,
1079 0x51,0x52,0x53,0x54,0x55,0x56,0x57,0x58,0x59,0x5a,
1080 0x5b,0x5c,0x5d,0x5e,0x5f,0x68,0x69,0x6a,0x6b,0x6c,
1081 0x6d,0x6e,0x70,0x71,0x72,0x73,0x74,0x75,0x76,0x78,
1082 0x79,0x7a,0x7b,0x7c,0x7d,0x7e,0x80,0x81,0x82,0x83,
1083 0x84,0x85,0x86,0x87,0x88,0x89,0x8a,0x8b,0x8c,0x8d,
1084 0x8e,0x8f,0x90,0x91,0x98,0x99,0x9c,0x9d,0x9e,0x9f,
1085 0xa0,0xa1,0xa2,0xa3,0xa4,0xa5,0xa6,0xb4,0xb5,0xb6,
1086 0xb7,0xb8,0xb9,EOT},
1087 {0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,
1088 0x44,0x00,0x00,MISC,MISC,NANA,NANA,0x00,0x40,0x00,
1089 0x00,MISC,MISC,NANA,NANA,0x00,0x00,MISC,MISC,MISC,
1090 MISC,MISC,MISC,MISC,MISC,MISC,MISC,MISC,MISC,MISC,
1091 MISC,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1092 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,0x00,
1093 0x00,0x7f,0x7f,0x7f,0x40,0x00,0x00,0x90,0x00,0x00,
1094 0x12,0x60,0x00,0x00,0x00,0x7f,0x7f,0x7f,0x00,0x00,
1095 0x7f,0x0f,0x7f,0x7f,0x7f,0x00,0x00,0x7f,0x0f,0x7f,
1096 0x7f,0x7f,0x00,0x00,0x7f,0x0f,MISC,MISC,MISC,MISC,
1097 NANA,NANA,NANA,NANA,0x00,0x00,0x00,0x00,0x00,0x00,
1098 0x00,MISC,0x00,0x00,0x00,0x00,0x00,NANA,0x00,NANA,
1099 0x7f,0x7f,0x7f,0x00,0x00,0x7f,0x0f,NANA,NANA,NANA,
1100 NANA,NANA,NANA,EOT}},
1101 {EOT}}},
1102 {0x8716, "IT8716F", {
1103 {NOLDN, NULL,
1104 {0x00,0x04,0x05,0x06,0x07,0x08,0x09,0x0b,0x0c,0x10,
1105 0x11,0x12,0x13,0x14,0x15,0x16,0x17,0x1b,0x1c,0x1d,
1106 0x30,0x31,0x32,0x33,0x34,0x35,0x36,0x37,0x38,0x39,
1107 0x3a,0x3b,0x3c,0x3d,0x3e,0x3f,0x40,0x41,0x42,0x43,
1108 0x44,0x45,0x48,0x50,0x51,0x52,0x53,0x54,0x56,0x57,
1109 0x59,0x5c,
1110 0x5d,0x5e,0x5f,0x60,0x61,0x62,0x63,0x64,0x65,0x68,
1111 0x69,0x6a,0x6b,0x6c,0x6d,0x70,0x71,0x72,0x73,0x74,
1112 0x75,0x84,0x85,0x86,0x87,0x88,0x89,0x8c,0x8d,0x8e,
1113 0x8f,0x90,0x91,0x92,0x93,0x94,0x95,0x98,0x99,0x9a,
1114 0x9b,0x9c,0x9d,EOT},
1115 {0x18,0x00,0x00,0x00,0x00,0x00,0x80,0x09,0x00,NANA,
1116 NANA,NANA,0x07,0x50,NANA,NANA,NANA,NANA,NANA,NANA,
1117 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1118 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1119 NANA,NANA,RSVD,0x00,0x00,0x7f,0x7f,0x7f,0x00,0x00,
1120 0x00,0x00,
1121 0x00,0x00,0x00,0x7f,0x7f,0x7f,0x00,0x00,0x7f,0x7f,
1122 0x7f,0x7f,0x00,0x00,0x7f,0x7f,0x7f,0x7f,0x00,0x00,
1123 0x7f,NANA,NANA,NANA,NANA,0x00,0x00,0x02,0x00,0x99,
1124 0x99,0x7f,0x7f,0x7f,0x00,0x00,0x7f,0x7f,0x7f,0x7f,
1125 0x00,0x00,0x7f,EOT}},
1126 {EOT}}},
1127 {0x8718, "IT8718F", {
1128 {NOLDN, NULL,
1129 {0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07,0x08,0x09,
1130 0x0a,0x0b,0x0c,0x0d,0x0e,0x0f,0x10,0x11,0x12,0x13,
1131 0x14,0x15,0x16,0x17,0x18,0x19,0x1a,0x1b,0x1c,0x1d,
1132 0x20,0x21,0x22,0x23,0x24,0x25,0x26,0x27,0x28,0x29,
1133 0x2a,0x2b,0x30,0x31,0x32,0x33,0x34,0x35,0x36,0x37,
1134 0x38,0x39,0x3a,0x3b,0x3c,0x3d,0x3e,0x3f,0x40,0x41,
1135 0x42,0x43,0x44,0x45,0x50,0x51,0x52,0x53,0x54,0x56,
1136 0x57,0x58,0x59,0x5b,0x5c,0x5d,0x5e,0x5f,0x60,0x61,
1137 0x62,0x63,0x64,0x65,0x68,0x69,0x6a,0x6b,0x6c,0x6d,
1138 0x70,0x71,0x72,0x73,0x74,0x75,0x80,0x81,0x82,0x83,
1139 0x88,0x89,0x8a,0x8b,0x8c,0x8d,0x8e,0x8f,0x90,0x91,
1140 0x92,0x94,0x95,0x96,0xa0,0xa1,0xa2,0xa3,0xa4,0xa5,
1141 0xa6,EOT},
1142 {0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,
1143 0x40,0x09,0x00,NANA,NANA,NANA,NANA,NANA,NANA,0x07,
1144 0x50,MISC,MISC,MISC,NANA,NANA,NANA,NANA,NANA,NANA,
1145 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1146 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1147 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1148 NANA,NANA,NANA,NANA,0x00,0x00,0x7f,0x7f,0x7f,0x00,
1149 0x00,0x90,0x00,0x12,0x00,0x00,0x00,0x00,0x7f,0x7f,
1150 0x7f,0x00,0x00,0x7f,0x7f,0x7f,0x7f,0x00,0x00,0x7f,
1151 0x7f,0x7f,0x7f,0x00,0x00,0x7f,NANA,NANA,NANA,NANA,
1152 0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0xff,0x00,
1153 0x00,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
1154 0x00,EOT}},
1155 {EOT}}},
1156 {0x8783, "IT8783E/F", {
1157 {NOLDN, NULL,
1158 {0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07,0x08,0x09,
1159 0x0a,0x0b,0x0c,0x0d,0x0e,0x0f,0x10,0x11,0x12,0x13,
1160 0x14,0x15,0x16,0x17,0x18,0x19,0x1a,0x1b,0x1c,0x1d,
1161 0x20,0x21,0x22,0x23,0x24,0x25,0x26,0x27,0x28,0x29,
1162 0x2a,0x2b,0x2c,0x2d,0x2e,0x2f,0x30,0x31,0x32,0x33,
1163 0x34,0x35,0x36,0x37,0x38,0x39,0x3a,0x3b,0x3c,0x3d,
1164 0x3e,0x3f,0x40,0x41,0x42,0x43,0x44,0x45,0x46,0x47,
1165 0x48,0x49,0x4a,0x4b,0x50,0x51,0x52,0x53,0x54,0x55,
1166 0x56,0x57,0x58,0x59,0x5a,0x5b,0x5c,0x5d,0x5e,0x5f,
1167 0x60,0x61,0x62,0x63,0x64,0x65,0x68,0x69,0x6a,0x6b,
1168 0x6c,0x6d,0x70,0x71,0x72,0x73,0x74,0x75,0x88,0x89,
1169 0x8a,0x8b,0x8c,0x8d,0x8e,EOT},
1170 {0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,
1171 0x54,0x09,0x00,NANA,NANA,NANA,MISC,MISC,MISC,0x07,
1172 0x50,MISC,MISC,MISC,NANA,NANA,NANA,MISC,MISC,MISC,
1173 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1174 NANA,NANA,NANA,NANA,NANA,NANA,MISC,MISC,MISC,MISC,
1175 MISC,MISC,MISC,MISC,MISC,MISC,MISC,MISC,MISC,MISC,
1176 MISC,MISC,MISC,MISC,MISC,MISC,MISC,MISC,0x5f,0x74,
1177 0x2d,0x40,0xab,0x22,0x00,0x00,0x7f,0x7f,0x7f,0x50,
1178 0x00,0x00,0x90,0x00,MISC,0x12,0x60,0x00,0x00,0x00,
1179 0x7f,0x7f,0x7f,0x00,0x00,0x7f,0x7f,0x7f,0x7f,0x00,
1180 0x00,0x7f,0x7f,0x7f,0x7f,0x00,0x00,0x7f,MISC,0x00,
1181 0x00,0x00,0x00,MISC,0x02,EOT}},
1182 {EOT}}},
1183 {0x8786, "IT8786E-I", {
1184 {NOLDN, NULL,
1185 {0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07,0x08,0x09,
1186 0x0a,0x0b,0x0c,0x0d,0x0e,0x0f,0x10,0x11,0x12,0x13,
1187 0x14,0x15,0x16,0x17,0x18,0x19,0x1a,0x1b,0x1c,0x1d,
1188 0x20,0x21,0x22,0x23,0x24,0x27,0x28,0x29,0x2a,0x2b,
1189 0x30,0x31,0x32,0x33,0x34,0x35,0x36,0x37,0x38,0x39,
1190 0x3e,0x3f,0x40,0x41,0x42,0x43,0x44,0x45,0x50,0x51,
1191 0x52,0x53,0x54,0x55,0x56,0x57,0x58,0x59,0x5b,0x5c,
1192 0x5d,0x5e,0x5f,0x60,0x61,0x62,0x63,0x64,0x65,0x66,
1193 0x68,0x69,0x6a,0x6b,0x6c,0x6d,0x6e,0x70,0x71,0x72,
1194 0x73,0x74,0x75,0x76,0x80,0x81,0x82,0x83,0x84,0x85,
1195 0x86,0x87,0x88,0x89,0x8a,0x8b,0x8c,0x8d,0x8e,0x8f,
1196 0x90,0x91,0x92,0x93,0x94,0x95,0x96,0x97,0x98,0x99,
1197 0x9c,0x9d,0x9e,0x9f,EOT},
1198 {0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,
1199 0x44,0x0F,0x00,NANA,NANA,NANA,MISC,MISC,MISC,0x07,
1200 0x40,0x00,0x00,0x00,NANA,NANA,NANA,MISC,MISC,MISC,
1201 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1202 MISC,MISC,MISC,MISC,MISC,MISC,MISC,MISC,MISC,MISC,
1203 MISC,MISC,MISC,MISC,MISC,MISC,MISC,MISC,0x00,0x00,
1204 0x7f,0x7f,0x7f,0x40,0x00,0x00,0x90,0x00,0x12,0x60,
1205 0x00,0x00,0x00,0x7f,0x7f,0x7f,0x80,0x00,0x7f,0x0f,
1206 0x7f,0x7f,0x7f,0x80,0x00,0x7f,0x0f,0x7f,0x7f,0x7f,
1207 0x80,0x00,0x7f,0x0f,NANA,NANA,NANA,NANA,MISC,MISC
1208 MISC,MISC,0x00,0x00,0x00,0x00,0x00,0x00,0x00,NANA,
1209 0xff,0x00,0x00,0x00,0xff,0x00,0x00,0x00,MISC,0x00,
1210 0x00,MISC,0x00,MISC,EOT}},
1211 {EOT}}},
1212 {EOT}
1215 static const struct superio_registers bram_table[] = {
1216 {0x8516, "IT8516???", {
1217 {NOLDN, NULL,
1218 {0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07,
1219 0x08,0x09,0x0a,0x0b,0x0c,0x0d,0x0e,0x0f,EOT},
1220 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1221 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
1222 {NOLDN, NULL,
1223 {0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17,
1224 0x18,0x19,0x1a,0x1b,0x1c,0x1d,0x1e,0x1f,EOT},
1225 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1226 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
1227 {NOLDN, NULL,
1228 {0x20,0x21,0x22,0x23,0x24,0x25,0x26,0x27,
1229 0x28,0x29,0x2a,0x2b,0x2c,0x2d,0x2e,0x2f,EOT},
1230 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1231 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
1232 {NOLDN, NULL,
1233 {0x30,0x31,0x32,0x33,0x34,0x35,0x36,0x37,
1234 0x38,0x39,0x3a,0x3b,0x3c,0x3d,0x3e,0x3f,EOT},
1235 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1236 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
1237 {NOLDN, NULL,
1238 {0x40,0x41,0x42,0x43,0x44,0x45,0x46,0x47,
1239 0x48,0x49,0x4a,0x4b,0x4c,0x4d,0x4e,0x4f,EOT},
1240 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1241 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
1242 {NOLDN, NULL,
1243 {0x50,0x51,0x52,0x53,0x54,0x55,0x56,0x57,
1244 0x58,0x59,0x5a,0x5b,0x5c,0x5d,0x5e,0x5f,EOT},
1245 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1246 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
1247 {NOLDN, NULL,
1248 {0x60,0x61,0x62,0x63,0x64,0x65,0x66,0x67,
1249 0x68,0x69,0x6a,0x6b,0x6c,0x6d,0x6e,0x6f,EOT},
1250 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1251 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
1252 {NOLDN, NULL,
1253 {0x70,0x71,0x72,0x73,0x74,0x75,0x76,0x77,
1254 0x78,0x79,0x7a,0x7b,0x7c,0x7d,0x7e,0x7f,EOT},
1255 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1256 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
1257 {NOLDN, NULL,
1258 {0x80,0x81,0x82,0x83,0x84,0x85,0x86,0x87,
1259 0x88,0x89,0x8a,0x8b,0x8c,0x8d,0x8e,0x8f,EOT},
1260 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1261 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
1262 {NOLDN, NULL,
1263 {0x90,0x91,0x92,0x93,0x94,0x95,0x96,0x97,
1264 0x98,0x99,0x9a,0x9b,0x9c,0x9d,0x9e,0x9f,EOT},
1265 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1266 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
1267 {NOLDN, NULL,
1268 {0xa0,0xa1,0xa2,0xa3,0xa4,0xa5,0xa6,0xa7,
1269 0xa8,0xa9,0xaa,0xab,0xac,0xad,0xae,0xaf,EOT},
1270 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1271 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
1272 {NOLDN, NULL,
1273 {0xb0,0xb1,0xb2,0xb3,0xb4,0xb5,0xb6,0xb7,
1274 0xb8,0xb9,0xba,0xbb,0xbc,0xbd,0xbe,0xbf,EOT},
1275 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1276 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
1277 {NOLDN, NULL,
1278 {0xc0,0xc1,0xc2,0xc3,0xc4,0xc5,0xc6,0xc7,
1279 0xc8,0xc9,0xca,0xcb,0xcc,0xcd,0xce,0xcf,EOT},
1280 {NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,
1281 NANA,NANA,NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
1282 {EOT}}},
1283 {EOT}
1286 /* Works for: IT8661F/IT8770F */
1287 static const uint8_t initkey_it8661f[][4] = {
1288 {0x86, 0x61, 0x55, 0x55}, /* 0x3f0 */
1289 {0x86, 0x61, 0x55, 0xaa}, /* 0x3bd */
1290 {0x86, 0x61, 0xaa, 0x55}, /* 0x370 */
1293 /* Works for: IT8671F/IT8687R, IT8673F */
1294 static const uint8_t initkey_it8671f[][4] = {
1295 {0x86, 0x80, 0x55, 0x55}, /* 0x3f0 */
1296 {0x86, 0x80, 0x55, 0xaa}, /* 0x3bd */
1297 {0x86, 0x80, 0xaa, 0x55}, /* 0x370 */
1300 /* Works for: IT8661F/IT8770F, IT8671F/IT8687R, IT8673F. */
1301 static const uint8_t initkey_mbpnp[] = {
1302 0x6a, 0xb5, 0xda, 0xed, 0xf6, 0xfb, 0x7d, 0xbe, 0xdf, 0x6f, 0x37,
1303 0x1b, 0x0d, 0x86, 0xc3, 0x61, 0xb0, 0x58, 0x2c, 0x16, 0x8b, 0x45,
1304 0xa2, 0xd1, 0xe8, 0x74, 0x3a, 0x9d, 0xce, 0xe7, 0x73, 0x39,
1307 /* Works for: IT8661F/IT8770F, IT8671F/IT8687R, IT8673F. */
1308 static void enter_conf_mode_ite_legacy(uint16_t port, const uint8_t init[][4])
1310 int i, idx;
1312 /* Determine Super I/O config port. */
1313 idx = (port == 0x3f0) ? 0 : ((port == 0x3bd) ? 1 : 2);
1314 for (i = 0; i < 4; i++)
1315 OUTB(init[idx][i], ISA_PNP_ADDR);
1317 /* Sequentially write the 32 MB PnP init values. */
1318 for (i = 0; i < 32; i++)
1319 OUTB(initkey_mbpnp[i], port);
1322 static void enter_conf_mode_ite(uint16_t port)
1324 OUTB(0x87, port);
1325 OUTB(0x01, port);
1326 OUTB(0x55, port);
1327 OUTB((port == 0x2e) ? 0x55 : 0xaa, port);
1330 static void enter_conf_mode_ite_it8502e(uint16_t port)
1332 OUTB(0x85, port);
1333 OUTB(0x02, port);
1334 OUTB(0x55, port);
1335 OUTB((port == 0x2e) ? 0x55 : 0xaa, port);
1338 static void enter_conf_mode_ite_it8761e(uint16_t port)
1340 OUTB(0x87, port);
1341 OUTB(0x61, port);
1342 OUTB(0x55, port);
1343 OUTB((port == 0x2e) ? 0x55 : 0xaa, port);
1346 static void enter_conf_mode_ite_it8228e(uint16_t port)
1348 OUTB(0x82, port);
1349 OUTB(0x28, port);
1350 OUTB(0x55, port);
1351 OUTB((port == 0x2e) ? 0x55 : 0xaa, port);
1354 static void exit_conf_mode_ite(uint16_t port)
1356 regwrite(port, 0x02, 0x02);
1359 static int chip_found_at_port;
1361 static void probe_idregs_ite_helper(const char *init, uint16_t port)
1363 uint16_t id, chipver, ecport;
1365 probing_for("ITE", init, port);
1367 id = regval(port, CHIP_ID_BYTE1_REG) << 8;
1368 id |= regval(port, CHIP_ID_BYTE2_REG);
1369 chipver = regval(port, CHIP_VERSION_REG) & 0x0f; /* Only bits 3..0 */
1371 if (superio_unknown(reg_table, id)) {
1372 if (verbose)
1373 printf(NOTFOUND "id=0x%04x, rev=0x%01x\n", id, chipver);
1374 return;
1377 printf("Found ITE %s (id=0x%04x, rev=0x%01x) at 0x%x\n",
1378 get_superio_name(reg_table, id), id, chipver, port);
1379 chip_found = 1;
1380 chip_found_at_port = 1;
1382 dump_superio("ITE", reg_table, port, id, LDN_SEL);
1384 if (extra_dump) {
1385 regwrite(port, LDN_SEL, 0x04); /* Select LDN 4 (EC). */
1387 /* Get EC base address (stored in LDN 4, index 0x60/0x61). */
1388 ecport = regval(port, 0x60) << 8;
1389 ecport |= regval(port, 0x61);
1391 /* EC address register = EC base address + 5. */
1392 ecport += 5;
1394 printf("Environment controller (0x%04x)\n", ecport);
1395 dump_superio("ITE-EC", ec_table, ecport, id, LDN_SEL);
1397 regwrite(port, LDN_SEL, 0x10); /* Select LDN 16 (BRAM). */
1398 /* Get EC base address (stored in LDN 16, index 0x62/0x63). */
1399 ecport = regval(port, 0x62) << 8;
1400 ecport |= regval(port, 0x63);
1401 printf("BRAM (0x%04x)\n", ecport);
1402 dump_superio("ITE-BRAM", bram_table, ecport, id, LDN_SEL);
1406 void probe_idregs_ite(uint16_t port)
1408 chip_found_at_port = 0;
1410 if (port == 0x3f0 || port == 0x3bd || port == 0x370) {
1411 enter_conf_mode_ite_legacy(port, initkey_it8661f);
1412 probe_idregs_ite_helper("(init=legacy/it8661f) ", port);
1413 exit_conf_mode_ite(port);
1414 if (chip_found_at_port)
1415 return;
1417 enter_conf_mode_ite_legacy(port, initkey_it8671f);
1418 probe_idregs_ite_helper("(init=legacy/it8671f) ", port);
1419 exit_conf_mode_ite(port);
1420 if (chip_found_at_port)
1421 return;
1422 } else {
1423 enter_conf_mode_ite(port);
1424 probe_idregs_ite_helper("(init=standard) ", port);
1425 exit_conf_mode_ite(port);
1426 if (chip_found_at_port)
1427 return;
1429 enter_conf_mode_ite_it8502e(port);
1430 probe_idregs_ite_helper("(init=it8502e) ", port);
1431 exit_conf_mode_ite(port);
1432 if (chip_found_at_port)
1433 return;
1435 enter_conf_mode_ite_it8761e(port);
1436 probe_idregs_ite_helper("(init=it8761e) ", port);
1437 exit_conf_mode_ite(port);
1438 if (chip_found_at_port)
1439 return;
1441 enter_conf_mode_ite_it8228e(port);
1442 probe_idregs_ite_helper("(init=it8228e) ", port);
1443 exit_conf_mode_ite(port);
1444 if (chip_found_at_port)
1445 return;
1447 enter_conf_mode_winbond_fintek_ite_8787(port);
1448 probe_idregs_ite_helper("(init=0x87,0x87) ", port);
1449 exit_conf_mode_winbond_fintek_ite_8787(port);
1450 if (chip_found_at_port)
1451 return;
1455 void print_ite_chips(void)
1457 print_vendor_chips("ITE", reg_table);
1458 print_vendor_chips("ITE-EC", ec_table);