summaryrefslogtreecommitdiff
path: root/src/mainboard/bytedance/bd_egs/gpio.c
blob: d985b00b9b449a1c6045f29612cdb51a00b78ba5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
/* SPDX-License-Identifier: GPL-2.0-or-later */

#include "gpio.h"

static const struct pad_config gpio_table[] = {
	PAD_CFG_NF_OWNERSHIP(GPPC_A0, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_A1, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_A2, UP_20K, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_A3, UP_20K, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_A4, UP_20K, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_A5, UP_20K, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_A6, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_A7, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_A8, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_A9, DN_20K, DEEP, NF1, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_A10, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_A11, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPO(GPPC_A12, 0, DEEP),
	PAD_CFG_GPI_TRIG_OWN(GPPC_A13, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_A14, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPO(GPPC_A15, 1, DEEP),
	PAD_CFG_GPIO_OWNERSHIP(GPPC_A16, NONE, DEEP, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_A17, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_A18, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_A19, NONE, DEEP, OFF, ACPI),

	PAD_CFG_NF_OWNERSHIP(GPPC_B0, NONE, DEEP, NF4, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_B1, NONE, DEEP, NF4, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_B2, NONE, DEEP, NF4, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_B3, NONE, DEEP, NF4, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_B4, NONE, DEEP, NF4, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_B5, NONE, DEEP, NF4, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_B6, NONE, DEEP, OFF, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_B7, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_B8, NONE, DEEP, NF1, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_B9, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_B10, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_B11, NONE, DEEP, OFF, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_B12, NONE, DEEP, NF4, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_B13, NONE, DEEP, NF4, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_B14, NONE, DEEP, NF4, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_B15, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_B16, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_B17, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_B18, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_B19, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_B20, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_NMI(GPPC_B21, NONE, DEEP, LEVEL, INVERT),
	PAD_CFG_GPI_TRIG_OWN(GPPC_B22, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_B23, NONE, DEEP, OFF, ACPI),

	PAD_CFG_NF_OWNERSHIP(GPPC_C0, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_C1, NONE, DEEP, NF1, ACPI),
	PAD_CFG_GPO(GPPC_C2, 1, DEEP),
	PAD_CFG_GPI_TRIG_OWN(GPPC_C3, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_C4, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_C5, NONE, DEEP, OFF, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_C6, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_C7, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_C8, NONE, DEEP, NF1, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_C9, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_C10, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPO(GPPC_C11, 1, DEEP),
	PAD_CFG_GPI_TRIG_OWN(GPPC_C12, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_C13, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPO(GPPC_C14, 1, DEEP),
	PAD_CFG_GPI_TRIG_OWN(GPPC_C15, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_C16, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPO(GPPC_C17, 1, PLTRST),
	PAD_CFG_GPI_TRIG_OWN(GPPC_C18, NONE, RSMRST, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_C19, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_C20, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_C21, NONE, DEEP, OFF, ACPI),

	PAD_CFG_NF_OWNERSHIP(GPP_D0, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_D1, NONE, DEEP, NF1, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_D2, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPO(GPP_D3, 0, DEEP),
	PAD_CFG_GPO(GPP_D4, 0, DEEP),
	PAD_CFG_GPO(GPP_D5, 0, DEEP),
	PAD_CFG_GPI_TRIG_OWN(GPP_D6, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_D7, NONE, DEEP, OFF, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_D8, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_D9, NONE, DEEP, NF1, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_D10, NONE, DEEP, OFF, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_D11, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_D12, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_D13, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_D14, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_D15, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_D16, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_D17, NONE, DEEP, NF1, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_D18, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_D19, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_D20, NONE, DEEP, OFF, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_D21, NONE, DEEP, NF1, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_D22, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_D23, NONE, DEEP, OFF, ACPI),

	PAD_CFG_GPI_TRIG_OWN(GPP_E0, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_E1, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_E2, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_E3, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPO(GPP_E4, 0, DEEP),			      // FIXME: GpioOutDefault
	PAD_CFG_GPO(GPP_E5, 0, DEEP),			      // FIXME: GpioOutDefault
	PAD_CFG_GPI_TRIG_OWN(GPP_E6, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_E7, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_E8, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_E9, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_E10, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPO(GPP_E11, 0, DEEP),			      // FIXME: GpioOutDefault
	PAD_CFG_GPI_TRIG_OWN(GPP_E12, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_E13, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_E14, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_E15, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_E16, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_E17, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_E18, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_E19, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPO(GPP_E20, 0, DEEP),
	PAD_CFG_GPO(GPP_E21, 0, DEEP),
	PAD_CFG_GPO(GPP_E22, 0, DEEP),
	PAD_CFG_GPO(GPP_E23, 0, DEEP),

	PAD_CFG_GPI_TRIG_OWN(GPPC_H0, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_H1, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPO(GPPC_H2, 0, DEEP),
	PAD_CFG_GPO(GPPC_H3, 0, DEEP),
	PAD_CFG_GPO(GPPC_H4, 0, DEEP),
	PAD_CFG_GPO(GPPC_H5, 0, DEEP),
	PAD_CFG_GPI_TRIG_OWN(GPPC_H6, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_H7, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPO(GPPC_H8, 0, DEEP),
	PAD_CFG_GPO(GPPC_H9, 0, DEEP),
	PAD_CFG_GPO(GPPC_H10, 0, DEEP),
	PAD_CFG_GPO(GPPC_H11, 0, DEEP),
	PAD_CFG_GPO(GPPC_H12, 0, DEEP),
	PAD_CFG_GPO(GPPC_H13, 0, DEEP),
	PAD_CFG_GPO(GPPC_H14, 0, DEEP),
	PAD_CFG_GPI_TRIG_OWN(GPPC_H15, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_H16, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_H17, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_H18, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_H19, NONE, DEEP, OFF, ACPI),

	PAD_CFG_GPO(GPP_I0, 0, DEEP),
	PAD_CFG_GPO(GPP_I1, 0, DEEP),
	PAD_CFG_GPO(GPP_I2, 0, DEEP),
	PAD_CFG_GPO(GPP_I3, 0, DEEP),
	PAD_CFG_GPO(GPP_I4, 0, DEEP),
	PAD_CFG_GPO(GPP_I5, 0, DEEP),
	PAD_CFG_GPO(GPP_I6, 0, DEEP),
	PAD_CFG_GPO(GPP_I7, 0, DEEP),
	PAD_CFG_GPO(GPP_I8, 0, DEEP),
	PAD_CFG_GPO(GPP_I9, 0, DEEP),
	PAD_CFG_GPO(GPP_I10, 0, DEEP),
	PAD_CFG_GPO(GPP_I11, 0, DEEP),
	PAD_CFG_GPI_TRIG_OWN(GPP_I12, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_I13, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_I14, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_I15, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_I16, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPO(GPP_I17, 0, DEEP),
	PAD_CFG_GPO(GPP_I18, 0, DEEP),
	PAD_CFG_GPO(GPP_I19, 0, DEEP),
	PAD_CFG_GPO(GPP_I20, 0, DEEP),
	PAD_CFG_GPI_TRIG_OWN(GPP_I21, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_I22, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_I23, NONE, DEEP, OFF, ACPI),

	PAD_CFG_NF_OWNERSHIP(GPP_J0, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_J1, NONE, DEEP, NF1, ACPI),
	PAD_CFG_GPO(GPP_J2, 0, DEEP),
	PAD_CFG_NF_OWNERSHIP(GPP_J3, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_J4, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_J5, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_J6, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_J7, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_J8, NONE, DEEP, NF1, ACPI),
	PAD_CFG_GPO(GPP_J9, 0, DEEP),
	PAD_CFG_GPO(GPP_J10, 0, DEEP),
	PAD_CFG_GPO(GPP_J11, 0, DEEP),
	PAD_CFG_NF_OWNERSHIP(GPP_J12, UP_20K, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_J13, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_J14, UP_20K, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_J15, UP_20K, DEEP, NF1, ACPI),
	PAD_CFG_GPO(GPP_J16, 0, DEEP),
	PAD_CFG_GPO(GPP_J17, 0, DEEP),

	PAD_CFG_NF_OWNERSHIP(GPP_L0, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_L1, NONE, DEEP, NF1, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_L2, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_L3, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_L4, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_L5, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_L6, NONE, DEEP, OFF, DRIVER),
	PAD_CFG_GPI_TRIG_OWN(GPP_L7, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPO(GPP_L8, 0, DEEP),
	PAD_CFG_GPO(GPP_L9, 0, DEEP),
	PAD_CFG_GPO(GPP_L10, 0, DEEP),
	PAD_CFG_GPO(GPP_L11, 0, DEEP),
	PAD_CFG_GPO(GPP_L12, 0, DEEP),
	PAD_CFG_GPO(GPP_L13, 0, DEEP),
	PAD_CFG_GPO(GPP_L14, 0, DEEP),
	PAD_CFG_GPO(GPP_L15, 0, DEEP),
	PAD_CFG_GPO(GPP_L16, 0, DEEP),
	PAD_CFG_GPO(GPP_L17, 0, DEEP),

	PAD_CFG_GPI_TRIG_OWN(GPP_M0, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_M1, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_M2, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_M3, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_M4, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_M5, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_M6, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_M7, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_M8, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPO(GPP_M9, 0, DEEP),
	PAD_CFG_GPO(GPP_M10, 0, DEEP),
	PAD_CFG_GPI_TRIG_OWN(GPP_M11, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_M12, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPO(GPP_M13, 0, DEEP),
	PAD_CFG_GPO(GPP_M14, 0, DEEP),
	PAD_CFG_GPI_TRIG_OWN(GPP_M15, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_M16, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_M17, NONE, DEEP, OFF, ACPI),

	PAD_CFG_GPO(GPP_N0, 0, DEEP),
	PAD_CFG_GPO(GPP_N1, 0, DEEP),
	PAD_CFG_GPO(GPP_N2, 0, DEEP),
	PAD_CFG_GPO(GPP_N3, 0, DEEP),
	PAD_CFG_GPO(GPP_N4, 0, DEEP),
	PAD_CFG_GPO(GPP_N5, 0, DEEP),
	PAD_CFG_GPO(GPP_N6, 0, DEEP),
	PAD_CFG_GPO(GPP_N7, 0, DEEP),
	PAD_CFG_GPO(GPP_N8, 0, DEEP),
	PAD_CFG_GPO(GPP_N9, 0, DEEP),
	PAD_CFG_GPO(GPP_N10, 0, DEEP),
	PAD_CFG_GPO(GPP_N11, 0, DEEP),
	PAD_CFG_GPO(GPP_N12, 0, DEEP),
	PAD_CFG_GPO(GPP_N13, 0, DEEP),
	PAD_CFG_GPO(GPP_N14, 0, DEEP),
	PAD_CFG_GPO(GPP_N15, 0, DEEP),
	PAD_CFG_GPO(GPP_N16, 0, DEEP),
	PAD_CFG_GPO(GPP_N17, 0, DEEP),

	PAD_CFG_GPI_TRIG_OWN(GPP_O1, NONE, PWROK, OFF, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_O2, NONE, PWROK, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_O3, NONE, PWROK, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_O4, NONE, PWROK, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_O5, NONE, PWROK, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_O6, NONE, PWROK, NF1, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_O7, NONE, PWROK, OFF, ACPI),
	PAD_CFG_GPO(GPP_O8, 0, PWROK),
	PAD_CFG_GPO(GPP_O9, 0, PWROK),
	PAD_CFG_NF_OWNERSHIP(GPP_O10, NONE, PWROK, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_O11, NONE, PWROK, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_O12, NONE, PWROK, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_O13, NONE, PWROK, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_O14, NONE, PWROK, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_O15, NONE, PWROK, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPP_O16, NONE, PWROK, NF1, ACPI),

	PAD_CFG_GPI_TRIG_OWN(GPPC_S0, NONE, DEEP, OFF, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_S1, NONE, DEEP, NF1, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_S2, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_S3, NONE, RSMRST, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_S4, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_S5, NONE, DEEP, OFF, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_S6, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_S7, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_S8, NONE, DEEP, NF1, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_S9, NONE, DEEP, NF1, DRIVER),
	PAD_CFG_GPI_TRIG_OWN(GPPC_S10, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_S11, NONE, DEEP, OFF, ACPI),
};

static const struct pad_config override_fsp_gpio_table[] = {
	PAD_CFG_GPI_TRIG_OWN(GPPC_B10, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_B11, NONE, DEEP, OFF, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_B12, NONE, DEEP, NF4, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_B13, NONE, DEEP, NF4, ACPI),
	PAD_CFG_NF_OWNERSHIP(GPPC_B14, NONE, DEEP, NF4, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPPC_B15, NONE, DEEP, OFF, ACPI),
	PAD_CFG_GPI_TRIG_OWN(GPP_D22, NONE, DEEP, OFF, ACPI),
};

const struct pad_config *get_gpio_table(size_t *num)
{
	*num = ARRAY_SIZE(gpio_table);
	return gpio_table;
}

const struct pad_config *get_override_fsp_gpio_table(size_t *num)
{
	*num = ARRAY_SIZE(override_fsp_gpio_table);
	return override_fsp_gpio_table;
}