1 /** @file
2   GPIO pins,
3 
4   Copyright (c) 2019 Intel Corporation. All rights reserved. <BR>
5 
6   SPDX-License-Identifier: BSD-2-Clause-Patent
7 **/
8 
9 #ifndef _GPIO_PINS_CNL_H_H_
10 #define _GPIO_PINS_CNL_H_H_
11 ///
12 /// This header file should be used together with
13 /// PCH GPIO lib in C and ASL. All defines used
14 /// must match both ASL/C syntax
15 ///
16 
17 ///
18 /// Unique ID used in GpioPad defines
19 ///
20 #define GPIO_CNL_H_CHIPSET_ID       0x3
21 
22 ///
23 /// Use below for functions from PCH GPIO Lib which
24 /// require GpioGroup as argument
25 ///
26 #define GPIO_CNL_H_GROUP_GPP_A  0x0300
27 #define GPIO_CNL_H_GROUP_GPP_B  0x0301
28 #define GPIO_CNL_H_GROUP_GPP_C  0x0302
29 #define GPIO_CNL_H_GROUP_GPP_D  0x0303
30 #define GPIO_CNL_H_GROUP_GPP_E  0x0304
31 #define GPIO_CNL_H_GROUP_GPP_F  0x0305
32 #define GPIO_CNL_H_GROUP_GPP_G  0x0306
33 #define GPIO_CNL_H_GROUP_GPP_H  0x0307
34 #define GPIO_CNL_H_GROUP_GPP_I  0x0308
35 #define GPIO_CNL_H_GROUP_GPP_J  0x0309
36 #define GPIO_CNL_H_GROUP_GPP_K  0x030A
37 #define GPIO_CNL_H_GROUP_GPD    0x030B
38 #define GPIO_CNL_H_GROUP_VGPIO  0x030C
39 #define GPIO_CNL_H_GROUP_SPI    0x030D
40 #define GPIO_CNL_H_GROUP_AZA    0x030E
41 #define GPIO_CNL_H_GROUP_CPU    0x030F
42 #define GPIO_CNL_H_GROUP_JTAG   0x0310
43 
44 ///
45 /// Use below for functions from PCH GPIO Lib which
46 /// require GpioPad as argument. Encoding used here
47 /// has all information required by library functions
48 ///
49 #define GPIO_CNL_H_GPP_A0               0x03000000
50 #define GPIO_CNL_H_GPP_A1               0x03000001
51 #define GPIO_CNL_H_GPP_A2               0x03000002
52 #define GPIO_CNL_H_GPP_A3               0x03000003
53 #define GPIO_CNL_H_GPP_A4               0x03000004
54 #define GPIO_CNL_H_GPP_A5               0x03000005
55 #define GPIO_CNL_H_GPP_A6               0x03000006
56 #define GPIO_CNL_H_GPP_A7               0x03000007
57 #define GPIO_CNL_H_GPP_A8               0x03000008
58 #define GPIO_CNL_H_GPP_A9               0x03000009
59 #define GPIO_CNL_H_GPP_A10              0x0300000A
60 #define GPIO_CNL_H_GPP_A11              0x0300000B
61 #define GPIO_CNL_H_GPP_A12              0x0300000C
62 #define GPIO_CNL_H_GPP_A13              0x0300000D
63 #define GPIO_CNL_H_GPP_A14              0x0300000E
64 #define GPIO_CNL_H_GPP_A15              0x0300000F
65 #define GPIO_CNL_H_GPP_A16              0x03000010
66 #define GPIO_CNL_H_GPP_A17              0x03000011
67 #define GPIO_CNL_H_GPP_A18              0x03000012
68 #define GPIO_CNL_H_GPP_A19              0x03000013
69 #define GPIO_CNL_H_GPP_A20              0x03000014
70 #define GPIO_CNL_H_GPP_A21              0x03000015
71 #define GPIO_CNL_H_GPP_A22              0x03000016
72 #define GPIO_CNL_H_GPP_A23              0x03000017
73 #define GPIO_CNL_H_ESPI_CLK_LOOPBK      0x03000018
74 
75 #define GPIO_CNL_H_GPP_B0               0x03010000
76 #define GPIO_CNL_H_GPP_B1               0x03010001
77 #define GPIO_CNL_H_GPP_B2               0x03010002
78 #define GPIO_CNL_H_GPP_B3               0x03010003
79 #define GPIO_CNL_H_GPP_B4               0x03010004
80 #define GPIO_CNL_H_GPP_B5               0x03010005
81 #define GPIO_CNL_H_GPP_B6               0x03010006
82 #define GPIO_CNL_H_GPP_B7               0x03010007
83 #define GPIO_CNL_H_GPP_B8               0x03010008
84 #define GPIO_CNL_H_GPP_B9               0x03010009
85 #define GPIO_CNL_H_GPP_B10              0x0301000A
86 #define GPIO_CNL_H_GPP_B11              0x0301000B
87 #define GPIO_CNL_H_GPP_B12              0x0301000C
88 #define GPIO_CNL_H_GPP_B13              0x0301000D
89 #define GPIO_CNL_H_GPP_B14              0x0301000E
90 #define GPIO_CNL_H_GPP_B15              0x0301000F
91 #define GPIO_CNL_H_GPP_B16              0x03010010
92 #define GPIO_CNL_H_GPP_B17              0x03010011
93 #define GPIO_CNL_H_GPP_B18              0x03010012
94 #define GPIO_CNL_H_GPP_B19              0x03010013
95 #define GPIO_CNL_H_GPP_B20              0x03010014
96 #define GPIO_CNL_H_GPP_B21              0x03010015
97 #define GPIO_CNL_H_GPP_B22              0x03010016
98 #define GPIO_CNL_H_GPP_B23              0x03010017
99 #define GPIO_CNL_H_GSPI0_CLK_LOOPBK     0x03010018
100 #define GPIO_CNL_H_GSPI1_CLK_LOOPBK     0x03010019
101 
102 #define GPIO_CNL_H_GPP_C0               0x03020000
103 #define GPIO_CNL_H_GPP_C1               0x03020001
104 #define GPIO_CNL_H_GPP_C2               0x03020002
105 #define GPIO_CNL_H_GPP_C3               0x03020003
106 #define GPIO_CNL_H_GPP_C4               0x03020004
107 #define GPIO_CNL_H_GPP_C5               0x03020005
108 #define GPIO_CNL_H_GPP_C6               0x03020006
109 #define GPIO_CNL_H_GPP_C7               0x03020007
110 #define GPIO_CNL_H_GPP_C8               0x03020008
111 #define GPIO_CNL_H_GPP_C9               0x03020009
112 #define GPIO_CNL_H_GPP_C10              0x0302000A
113 #define GPIO_CNL_H_GPP_C11              0x0302000B
114 #define GPIO_CNL_H_GPP_C12              0x0302000C
115 #define GPIO_CNL_H_GPP_C13              0x0302000D
116 #define GPIO_CNL_H_GPP_C14              0x0302000E
117 #define GPIO_CNL_H_GPP_C15              0x0302000F
118 #define GPIO_CNL_H_GPP_C16              0x03020010
119 #define GPIO_CNL_H_GPP_C17              0x03020011
120 #define GPIO_CNL_H_GPP_C18              0x03020012
121 #define GPIO_CNL_H_GPP_C19              0x03020013
122 #define GPIO_CNL_H_GPP_C20              0x03020014
123 #define GPIO_CNL_H_GPP_C21              0x03020015
124 #define GPIO_CNL_H_GPP_C22              0x03020016
125 #define GPIO_CNL_H_GPP_C23              0x03020017
126 
127 #define GPIO_CNL_H_GPP_D0               0x03030000
128 #define GPIO_CNL_H_GPP_D1               0x03030001
129 #define GPIO_CNL_H_GPP_D2               0x03030002
130 #define GPIO_CNL_H_GPP_D3               0x03030003
131 #define GPIO_CNL_H_GPP_D4               0x03030004
132 #define GPIO_CNL_H_GPP_D5               0x03030005
133 #define GPIO_CNL_H_GPP_D6               0x03030006
134 #define GPIO_CNL_H_GPP_D7               0x03030007
135 #define GPIO_CNL_H_GPP_D8               0x03030008
136 #define GPIO_CNL_H_GPP_D9               0x03030009
137 #define GPIO_CNL_H_GPP_D10              0x0303000A
138 #define GPIO_CNL_H_GPP_D11              0x0303000B
139 #define GPIO_CNL_H_GPP_D12              0x0303000C
140 #define GPIO_CNL_H_GPP_D13              0x0303000D
141 #define GPIO_CNL_H_GPP_D14              0x0303000E
142 #define GPIO_CNL_H_GPP_D15              0x0303000F
143 #define GPIO_CNL_H_GPP_D16              0x03030010
144 #define GPIO_CNL_H_GPP_D17              0x03030011
145 #define GPIO_CNL_H_GPP_D18              0x03030012
146 #define GPIO_CNL_H_GPP_D19              0x03030013
147 #define GPIO_CNL_H_GPP_D20              0x03030014
148 #define GPIO_CNL_H_GPP_D21              0x03030015
149 #define GPIO_CNL_H_GPP_D22              0x03030016
150 #define GPIO_CNL_H_GPP_D23              0x03030017
151 
152 #define GPIO_CNL_H_GPP_E0               0x03040000
153 #define GPIO_CNL_H_GPP_E1               0x03040001
154 #define GPIO_CNL_H_GPP_E2               0x03040002
155 #define GPIO_CNL_H_GPP_E3               0x03040003
156 #define GPIO_CNL_H_GPP_E4               0x03040004
157 #define GPIO_CNL_H_GPP_E5               0x03040005
158 #define GPIO_CNL_H_GPP_E6               0x03040006
159 #define GPIO_CNL_H_GPP_E7               0x03040007
160 #define GPIO_CNL_H_GPP_E8               0x03040008
161 #define GPIO_CNL_H_GPP_E9               0x03040009
162 #define GPIO_CNL_H_GPP_E10              0x0304000A
163 #define GPIO_CNL_H_GPP_E11              0x0304000B
164 #define GPIO_CNL_H_GPP_E12              0x0304000C
165 
166 #define GPIO_CNL_H_GPP_F0               0x03050000
167 #define GPIO_CNL_H_GPP_F1               0x03050001
168 #define GPIO_CNL_H_GPP_F2               0x03050002
169 #define GPIO_CNL_H_GPP_F3               0x03050003
170 #define GPIO_CNL_H_GPP_F4               0x03050004
171 #define GPIO_CNL_H_GPP_F5               0x03050005
172 #define GPIO_CNL_H_GPP_F6               0x03050006
173 #define GPIO_CNL_H_GPP_F7               0x03050007
174 #define GPIO_CNL_H_GPP_F8               0x03050008
175 #define GPIO_CNL_H_GPP_F9               0x03050009
176 #define GPIO_CNL_H_GPP_F10              0x0305000A
177 #define GPIO_CNL_H_GPP_F11              0x0305000B
178 #define GPIO_CNL_H_GPP_F12              0x0305000C
179 #define GPIO_CNL_H_GPP_F13              0x0305000D
180 #define GPIO_CNL_H_GPP_F14              0x0305000E
181 #define GPIO_CNL_H_GPP_F15              0x0305000F
182 #define GPIO_CNL_H_GPP_F16              0x03050010
183 #define GPIO_CNL_H_GPP_F17              0x03050011
184 #define GPIO_CNL_H_GPP_F18              0x03050012
185 #define GPIO_CNL_H_GPP_F19              0x03050013
186 #define GPIO_CNL_H_GPP_F20              0x03050014
187 #define GPIO_CNL_H_GPP_F21              0x03050015
188 #define GPIO_CNL_H_GPP_F22              0x03050016
189 #define GPIO_CNL_H_GPP_F23              0x03050017
190 
191 #define GPIO_CNL_H_GPP_G0               0x03060000
192 #define GPIO_CNL_H_GPP_G1               0x03060001
193 #define GPIO_CNL_H_GPP_G2               0x03060002
194 #define GPIO_CNL_H_GPP_G3               0x03060003
195 #define GPIO_CNL_H_GPP_G4               0x03060004
196 #define GPIO_CNL_H_GPP_G5               0x03060005
197 #define GPIO_CNL_H_GPP_G6               0x03060006
198 #define GPIO_CNL_H_GPP_G7               0x03060007
199 
200 #define GPIO_CNL_H_GPP_H0               0x03070000
201 #define GPIO_CNL_H_GPP_H1               0x03070001
202 #define GPIO_CNL_H_GPP_H2               0x03070002
203 #define GPIO_CNL_H_GPP_H3               0x03070003
204 #define GPIO_CNL_H_GPP_H4               0x03070004
205 #define GPIO_CNL_H_GPP_H5               0x03070005
206 #define GPIO_CNL_H_GPP_H6               0x03070006
207 #define GPIO_CNL_H_GPP_H7               0x03070007
208 #define GPIO_CNL_H_GPP_H8               0x03070008
209 #define GPIO_CNL_H_GPP_H9               0x03070009
210 #define GPIO_CNL_H_GPP_H10              0x0307000A
211 #define GPIO_CNL_H_GPP_H11              0x0307000B
212 #define GPIO_CNL_H_GPP_H12              0x0307000C
213 #define GPIO_CNL_H_GPP_H13              0x0307000D
214 #define GPIO_CNL_H_GPP_H14              0x0307000E
215 #define GPIO_CNL_H_GPP_H15              0x0307000F
216 #define GPIO_CNL_H_GPP_H16              0x03070010
217 #define GPIO_CNL_H_GPP_H17              0x03070011
218 #define GPIO_CNL_H_GPP_H18              0x03070012
219 #define GPIO_CNL_H_GPP_H19              0x03070013
220 #define GPIO_CNL_H_GPP_H20              0x03070014
221 #define GPIO_CNL_H_GPP_H21              0x03070015
222 #define GPIO_CNL_H_GPP_H22              0x03070016
223 #define GPIO_CNL_H_GPP_H23              0x03070017
224 
225 #define GPIO_CNL_H_GPP_I0               0x03080000
226 #define GPIO_CNL_H_GPP_I1               0x03080001
227 #define GPIO_CNL_H_GPP_I2               0x03080002
228 #define GPIO_CNL_H_GPP_I3               0x03080003
229 #define GPIO_CNL_H_GPP_I4               0x03080004
230 #define GPIO_CNL_H_GPP_I5               0x03080005
231 #define GPIO_CNL_H_GPP_I6               0x03080006
232 #define GPIO_CNL_H_GPP_I7               0x03080007
233 #define GPIO_CNL_H_GPP_I8               0x03080008
234 #define GPIO_CNL_H_GPP_I9               0x03080009
235 #define GPIO_CNL_H_GPP_I10              0x0308000A
236 #define GPIO_CNL_H_GPP_I11              0x0308000B
237 #define GPIO_CNL_H_GPP_I12              0x0308000C
238 #define GPIO_CNL_H_GPP_I13              0x0308000D
239 #define GPIO_CNL_H_GPP_I14              0x0308000E
240 #define GPIO_CNL_H_SYS_PWROK            0x0308000F
241 #define GPIO_CNL_H_SYS_RESETB           0x03080010
242 #define GPIO_CNL_H_MLK_RSTB             0x03080011
243 
244 #define GPIO_CNL_H_GPP_J0               0x03090000
245 #define GPIO_CNL_H_GPP_J1               0x03090001
246 #define GPIO_CNL_H_GPP_J2               0x03090002
247 #define GPIO_CNL_H_GPP_J3               0x03090003
248 #define GPIO_CNL_H_GPP_J4               0x03090004
249 #define GPIO_CNL_H_GPP_J5               0x03090005
250 #define GPIO_CNL_H_GPP_J6               0x03090006
251 #define GPIO_CNL_H_GPP_J7               0x03090007
252 #define GPIO_CNL_H_GPP_J8               0x03090008
253 #define GPIO_CNL_H_GPP_J9               0x03090009
254 #define GPIO_CNL_H_GPP_J10              0x0309000A
255 #define GPIO_CNL_H_GPP_J11              0x0309000B
256 
257 #define GPIO_CNL_H_GPP_K0               0x030A0000
258 #define GPIO_CNL_H_GPP_K1               0x030A0001
259 #define GPIO_CNL_H_GPP_K2               0x030A0002
260 #define GPIO_CNL_H_GPP_K3               0x030A0003
261 #define GPIO_CNL_H_GPP_K4               0x030A0004
262 #define GPIO_CNL_H_GPP_K5               0x030A0005
263 #define GPIO_CNL_H_GPP_K6               0x030A0006
264 #define GPIO_CNL_H_GPP_K7               0x030A0007
265 #define GPIO_CNL_H_GPP_K8               0x030A0008
266 #define GPIO_CNL_H_GPP_K9               0x030A0009
267 #define GPIO_CNL_H_GPP_K10              0x030A000A
268 #define GPIO_CNL_H_GPP_K11              0x030A000B
269 #define GPIO_CNL_H_GPP_K12              0x030A000C
270 #define GPIO_CNL_H_GPP_K13              0x030A000D
271 #define GPIO_CNL_H_GPP_K14              0x030A000E
272 #define GPIO_CNL_H_GPP_K15              0x030A000F
273 #define GPIO_CNL_H_GPP_K16              0x030A0010
274 #define GPIO_CNL_H_GPP_K17              0x030A0011
275 #define GPIO_CNL_H_GPP_K18              0x030A0012
276 #define GPIO_CNL_H_GPP_K19              0x030A0013
277 #define GPIO_CNL_H_GPP_K20              0x030A0014
278 #define GPIO_CNL_H_GPP_K21              0x030A0015
279 #define GPIO_CNL_H_GPP_K22              0x030A0016
280 #define GPIO_CNL_H_GPP_K23              0x030A0017
281 
282 #define GPIO_CNL_H_GPD0                 0x030B0000
283 #define GPIO_CNL_H_GPD1                 0x030B0001
284 #define GPIO_CNL_H_GPD2                 0x030B0002
285 #define GPIO_CNL_H_GPD3                 0x030B0003
286 #define GPIO_CNL_H_GPD4                 0x030B0004
287 #define GPIO_CNL_H_GPD5                 0x030B0005
288 #define GPIO_CNL_H_GPD6                 0x030B0006
289 #define GPIO_CNL_H_GPD7                 0x030B0007
290 #define GPIO_CNL_H_GPD8                 0x030B0008
291 #define GPIO_CNL_H_GPD9                 0x030B0009
292 #define GPIO_CNL_H_GPD10                0x030B000A
293 #define GPIO_CNL_H_GPD11                0x030B000B
294 #define GPIO_CNL_H_SLP_LANB             0x030B000C
295 #define GPIO_CNL_H_SLP_SUSB             0x030B000D
296 #define GPIO_CNL_H_SLP_WAKEB            0x030B000E
297 #define GPIO_CNL_H_SLP_DRAM_RESETB      0x030B000F
298 
299 #define GPIO_CNL_H_VGPIO0               0x030C0000
300 #define GPIO_CNL_H_VGPIO1               0x030C0001
301 #define GPIO_CNL_H_VGPIO2               0x030C0002
302 #define GPIO_CNL_H_VGPIO3               0x030C0003
303 #define GPIO_CNL_H_VGPIO4               0x030C0004
304 #define GPIO_CNL_H_VGPIO5               0x030C0005
305 #define GPIO_CNL_H_VGPIO6               0x030C0006
306 #define GPIO_CNL_H_VGPIO7               0x030C0007
307 #define GPIO_CNL_H_VGPIO8               0x030C0008
308 #define GPIO_CNL_H_VGPIO9               0x030C0009
309 #define GPIO_CNL_H_VGPIO10              0x030C000A
310 #define GPIO_CNL_H_VGPIO11              0x030C000B
311 #define GPIO_CNL_H_VGPIO12              0x030C000C
312 #define GPIO_CNL_H_VGPIO13              0x030C000D
313 #define GPIO_CNL_H_VGPIO14              0x030C000E
314 #define GPIO_CNL_H_VGPIO15              0x030C000F
315 #define GPIO_CNL_H_VGPIO16              0x030C0010
316 #define GPIO_CNL_H_VGPIO17              0x030C0011
317 #define GPIO_CNL_H_VGPIO18              0x030C0012
318 #define GPIO_CNL_H_VGPIO19              0x030C0013
319 #define GPIO_CNL_H_VGPIO20              0x030C0014
320 #define GPIO_CNL_H_VGPIO21              0x030C0015
321 #define GPIO_CNL_H_VGPIO22              0x030C0016
322 #define GPIO_CNL_H_VGPIO23              0x030C0017
323 #define GPIO_CNL_H_VGPIO24              0x030C0018
324 #define GPIO_CNL_H_VGPIO25              0x030C0019
325 #define GPIO_CNL_H_VGPIO26              0x030C001A
326 #define GPIO_CNL_H_VGPIO27              0x030C001B
327 #define GPIO_CNL_H_VGPIO28              0x030C001C
328 #define GPIO_CNL_H_VGPIO29              0x030C001D
329 #define GPIO_CNL_H_VGPIO30              0x030C001E
330 #define GPIO_CNL_H_VGPIO31              0x030C001F
331 #define GPIO_CNL_H_VGPIO32              0x030C0020
332 #define GPIO_CNL_H_VGPIO33              0x030C0021
333 #define GPIO_CNL_H_VGPIO34              0x030C0022
334 #define GPIO_CNL_H_VGPIO35              0x030C0023
335 #define GPIO_CNL_H_VGPIO36              0x030C0024
336 #define GPIO_CNL_H_VGPIO37              0x030C0025
337 #define GPIO_CNL_H_VGPIO38              0x030C0026
338 #define GPIO_CNL_H_VGPIO39              0x030C0027
339 
340 #define GPIO_CNL_H_SPI0_IO_2            0x030D0000
341 #define GPIO_CNL_H_SPI0_IO_3            0x030D0001
342 #define GPIO_CNL_H_SPI0_MOSI_IO_0       0x030D0002
343 #define GPIO_CNL_H_SPI0_MOSI_IO_1       0x030D0003
344 #define GPIO_CNL_H_SPI0_TPM_CSB         0x030D0004
345 #define GPIO_CNL_H_SPI0_FLASH_0_CSB     0x030D0005
346 #define GPIO_CNL_H_SPI0_FLASH_1_CSB     0x030D0006
347 #define GPIO_CNL_H_SPI0_CLK             0x030D0007
348 #define GPIO_CNL_H_SPI0_CLK_LOOPBK      0x030D0008
349 
350 #define GPIO_CNL_H_HDA_BCLK             0x030E0000
351 #define GPIO_CNL_H_HDA_RSTB             0x030E0001
352 #define GPIO_CNL_H_HDA_SYNC             0x030E0002
353 #define GPIO_CNL_H_HDA_SDO              0x030E0003
354 #define GPIO_CNL_H_HDA_SDI_0            0x030E0004
355 #define GPIO_CNL_H_HDA_SDI_1            0x030E0005
356 #define GPIO_CNL_H_SSP1_SFRM            0x030E0006
357 #define GPIO_CNL_H_SSP1_TXD             0x030E0007
358 
359 #define GPIO_CNL_H_HDACPU_SDI           0x030F0000
360 #define GPIO_CNL_H_HDACPU_SDO           0x030F0001
361 #define GPIO_CNL_H_HDACPU_SCLK          0x030F0002
362 #define GPIO_CNL_H_PM_SYNC              0x030F0003
363 #define GPIO_CNL_H_PECI                 0x030F0004
364 #define GPIO_CNL_H_CPUPWRGD             0x030F0005
365 #define GPIO_CNL_H_THRMTRIPB            0x030F0006
366 #define GPIO_CNL_H_PLTRST_CPUB          0x030F0007
367 #define GPIO_CNL_H_PM_DOWN              0x030F0008
368 #define GPIO_CNL_H_TRIGGER_IN           0x030F0009
369 #define GPIO_CNL_H_TRIGGER_OUT          0x030F000A
370 
371 #define GPIO_CNL_H_JTAG_TDO             0x03100000
372 #define GPIO_CNL_H_JTAGX                0x03100001
373 #define GPIO_CNL_H_PRDYB                0x03100002
374 #define GPIO_CNL_H_PREQB                0x03100003
375 #define GPIO_CNL_H_CPU_TRSTB            0x03100004
376 #define GPIO_CNL_H_JTAG_TDI             0x03100005
377 #define GPIO_CNL_H_JTAG_TMS             0x03100006
378 #define GPIO_CNL_H_JTAG_TCK             0x03100007
379 #define GPIO_CNL_H_ITP_PMODE            0x03100008
380 
381 #endif
382