1 /* SPDX-License-Identifier: GPL-2.0-only */
4 #include <variant/gpio.h>
6 static const struct pad_config gpio_table
[] = {
7 /* GPP_A14 GPIO */ PAD_NC(GPP_A14
, NONE
),
8 /* GPP_A16 GPIO */ PAD_NC(GPP_A16
, DN_20K
),
9 /* GPP_B4 GPIO */ PAD_CFG_GPO(GPP_B4
, 0, DEEP
),
10 /* GPP_B5 GPIO */ PAD_NC(GPP_B5
, NONE
),
11 /* GPP_B6 GPIO */ PAD_NC(GPP_B6
, NONE
),
12 /* GPP_B8 GPIO */ PAD_NC(GPP_B8
, NONE
),
13 /* GPP_B10 GPIO */ PAD_NC(GPP_B10
, NONE
),
14 /* GPP_B11 GPIO */ PAD_CFG_GPO(GPP_B11
, 1, DEEP
),
15 /* GPP_B14 SPKR */ PAD_CFG_NF(GPP_B14
, NONE
, DEEP
, NF1
),
16 /* GPP_B18 GPIO */ PAD_NC(GPP_B18
, NONE
),
17 /* GPP_B22 GPIO */ PAD_NC(GPP_B22
, NONE
),
18 /* GPP_C2 GPIO */ PAD_NC(GPP_C2
, NONE
),
19 /* GPP_C5 GPIO */ PAD_NC(GPP_C5
, NONE
),
20 /* GPP_C6 SML1CLK */ PAD_CFG_NF(GPP_C6
, NONE
, DEEP
, NF1
),
21 /* GPP_C7 SML1DATA */ PAD_CFG_NF(GPP_C7
, NONE
, DEEP
, NF1
),
22 /* GPP_C8 GPIO */ PAD_NC(GPP_C8
, NONE
),
23 /* GPP_C9 GPIO */ PAD_NC(GPP_C9
, NONE
),
24 /* GPP_C12 GPIO */ PAD_CFG_GPI(GPP_C12
, NONE
, DEEP
),
25 /* GPP_C13 GPIO */ PAD_CFG_GPI(GPP_C13
, NONE
, DEEP
),
26 /* GPP_C14 GPIO */ PAD_CFG_GPI(GPP_C14
, NONE
, DEEP
),
27 /* GPP_C15 GPIO */ PAD_CFG_GPI(GPP_C15
, NONE
, DEEP
),
28 /* GPP_C16 I2C0_SDA */ PAD_CFG_NF(GPP_C16
, NONE
, PLTRST
, NF1
),
29 /* GPP_C17 I2C0_SCL */ PAD_CFG_NF(GPP_C17
, NONE
, DEEP
, NF1
),
30 /* GPP_C20 UART2_RXD */ PAD_CFG_NF(GPP_C20
, NONE
, DEEP
, NF1
),
31 /* GPP_C21 UART2_TXD */ PAD_CFG_NF(GPP_C21
, NONE
, DEEP
, NF1
),
32 /* GPP_C22 UART2_RTS# */ PAD_CFG_NF(GPP_C22
, NONE
, DEEP
, NF1
),
33 /* GPP_C23 UART2_CTS# */ PAD_CFG_NF(GPP_C23
, NONE
, DEEP
, NF1
),
34 /* GPP_D1 GPIO */ PAD_CFG_GPI(GPP_D1
, NONE
, DEEP
),
35 /* GPP_D2 GPIO */ PAD_CFG_GPI(GPP_D2
, NONE
, DEEP
),
36 /* GPP_D3 GPIO */ PAD_CFG_GPO(GPP_D3
, 1, DEEP
),
37 /* GPP_D7 GPIO */ PAD_CFG_GPI(GPP_D7
, NONE
, PLTRST
),
38 /* GPP_D8 GPIO */ PAD_CFG_GPI(GPP_D8
, NONE
, PLTRST
),
39 /* GPP_D17 DMIC_CLK1 */ PAD_CFG_NF(GPP_D17
, NONE
, DEEP
, NF1
),
40 /* GPP_D18 DMIC_DATA1 */ PAD_CFG_NF(GPP_D18
, NONE
, DEEP
, NF1
),
41 /* GPP_D19 DMIC_CLK0 */ PAD_CFG_NF(GPP_D19
, NONE
, DEEP
, NF1
),
42 /* GPP_D20 DMIC_DATA0 */ PAD_CFG_NF(GPP_D20
, NONE
, DEEP
, NF1
),
43 /* GPP_D21 GPIO */ PAD_CFG_GPO(GPP_D21
, 1, DEEP
),
44 /* GPP_D22 GPIO */ PAD_CFG_GPI(GPP_D22
, NONE
, DEEP
),
45 /* GPP_G1 GPIO */ PAD_CFG_GPO(GPP_G1
, 1, PLTRST
),
46 /* GPP_G2 GPIO */ PAD_CFG_GPI(GPP_G2
, NONE
, PLTRST
),
47 /* GPP_G3 GPIO */ PAD_CFG_GPI_APIC(GPP_G3
, NONE
, DEEP
, LEVEL
, INVERT
),
48 /* I2S1_SFRM GPIO */ PAD_NC(I2S1_SFRM
, NONE
),
49 /* I2S1_TXD GPIO */ PAD_NC(I2S1_TXD
, NONE
),
50 /* GPD0 BATLOW# */ PAD_CFG_NF(GPD0
, NONE
, DEEP
, NF1
),
51 /* GPD1 ACPRESENT */ PAD_CFG_NF(GPD1
, NATIVE
, DEEP
, NF1
),
52 /* GPD7 GPIO */ PAD_CFG_GPO(GPD7
, 0, RSMRST
),
53 /* GPP_K0 GPIO */ PAD_CFG_GPI(GPP_K0
, NONE
, PLTRST
),
54 /* GPP_K1 GPIO */ PAD_CFG_GPI(GPP_K1
, NONE
, PLTRST
),
55 /* GPP_K2 GPIO */ PAD_CFG_GPI(GPP_K2
, NONE
, PLTRST
),
56 /* GPP_K3 GPIO */ PAD_CFG_GPI(GPP_K3
, NONE
, PLTRST
),
57 /* GPP_K4 GPIO */ PAD_CFG_GPO(GPP_K4
, 1, PWROK
),
58 /* GPP_K5 GPIO */ PAD_CFG_GPO(GPP_K5
, 1, PWROK
),
59 /* GPP_K8 GPIO */ PAD_NC(GPP_K8
, NONE
),
60 /* GPP_K9 GPIO */ PAD_NC(GPP_K9
, NONE
),
61 /* GPP_K10 GPIO */ PAD_NC(GPP_K10
, NONE
),
62 /* GPP_K11 GPIO */ PAD_NC(GPP_K11
, NONE
),
63 /* GPP_K20 GPIO */ PAD_CFG_GPO(GPP_K20
, 1, PLTRST
),
64 /* GPP_K21 GPIO */ PAD_NC(GPP_K21
, NONE
),
65 /* GPP_H0 GPIO */ PAD_CFG_GPI(GPP_H0
, NONE
, PLTRST
),
66 /* GPP_H2 GPIO */ PAD_NC(GPP_H2
, NONE
),
67 /* GPP_H3 GPIO */ PAD_NC(GPP_H3
, NONE
),
68 /* GPP_H10 GPIO */ PAD_CFG_GPI(GPP_H10
, NONE
, DEEP
),
69 /* GPP_H15 GPIO */ PAD_CFG_GPO(GPP_H15
, 1, DEEP
),
70 /* GPP_H17 GPIO */ PAD_CFG_GPO(GPP_H17
, 1, DEEP
),
71 /* GPP_E0 SATAXPCIE0 */ PAD_CFG_NF(GPP_E0
, NONE
, DEEP
, NF1
),
72 /* GPP_E1 GPIO */ PAD_NC(GPP_E1
, NONE
),
73 /* GPP_E2 GPIO */ PAD_NC(GPP_E2
, NONE
),
74 /* GPP_E4 SATA_DEVSLP0 */ PAD_CFG_NF(GPP_E4
, NONE
, DEEP
, NF1
),
75 /* GPP_E5 GPIO */ PAD_CFG_GPI(GPP_E5
, NONE
, DEEP
),
76 /* GPP_E6 GPIO */ PAD_CFG_GPI(GPP_E6
, NONE
, DEEP
),
77 /* GPP_E8 SATALED# */ PAD_CFG_NF(GPP_E8
, NONE
, DEEP
, NF1
),
78 /* GPP_E9 USB2_OC0# */ PAD_CFG_NF(GPP_E9
, UP_20K
, DEEP
, NF1
),
79 /* GPP_E10 USB2_OC1# */ PAD_CFG_NF(GPP_E10
, UP_20K
, DEEP
, NF1
),
80 /* GPP_E11 USB2_OC2# */ PAD_CFG_NF(GPP_E11
, UP_20K
, DEEP
, NF1
),
81 /* GPP_E12 GPIO */ PAD_CFG_GPO(GPP_E12
, 1, PLTRST
),
82 /* GPP_F1 GPIO */ PAD_NC(GPP_F1
, NONE
),
83 /* GPP_F2 GPIO */ PAD_NC(GPP_F2
, NONE
),
84 /* GPP_F3 GPIO */ PAD_NC(GPP_F3
, NONE
),
85 /* GPP_F4 GPIO */ PAD_NC(GPP_F4
, NONE
),
86 /* GPP_F5 GPIO */ PAD_CFG_GPO(GPP_F5
, 1, PLTRST
),
87 /* GPP_F6 SATA_DEVSLP4 */ PAD_CFG_NF(GPP_F6
, NONE
, DEEP
, NF1
),
88 /* GPP_F8 GPIO */ PAD_CFG_GPO(GPP_F8
, 0, DEEP
),
89 /* GPP_F9 GPIO */ PAD_CFG_GPO(GPP_F9
, 0, DEEP
),
90 /* GPP_F10 GPIO */ PAD_CFG_GPI(GPP_F10
, NONE
, PLTRST
),
91 /* GPP_F13 GPIO */ PAD_CFG_GPI(GPP_F13
, NONE
, PLTRST
),
92 /* GPP_F14 GPIO */ PAD_NC(GPP_F14
, NONE
),
93 /* GPP_F15 USB2_OC4# */ PAD_CFG_NF(GPP_F15
, UP_20K
, DEEP
, NF1
),
94 /* GPP_F16 USB2_OC5# */ PAD_CFG_NF(GPP_F16
, UP_20K
, DEEP
, NF1
),
95 /* GPP_F17 USB2_OC6# */ PAD_CFG_NF(GPP_F17
, UP_20K
, DEEP
, NF1
),
96 /* GPP_F18 GPIO */ PAD_CFG_GPI_APIC(GPP_F18
, NONE
, DEEP
, LEVEL
, INVERT
),
97 /* GPP_F19 eDP_VDDEN */ PAD_CFG_NF(GPP_F19
, NONE
, DEEP
, NF1
),
98 /* GPP_F20 eDP_BKLTEN */ PAD_CFG_NF(GPP_F20
, NONE
, DEEP
, NF1
),
99 /* GPP_F21 eDP_BKLTCTL */ PAD_CFG_NF(GPP_F21
, NONE
, DEEP
, NF1
),
100 /* GPP_F22 DDPF_CTRLCLK */ PAD_CFG_NF(GPP_F22
, NONE
, DEEP
, NF1
),
101 /* GPP_F23 DDPF_CTRLDATA */ PAD_CFG_NF(GPP_F23
, NONE
, DEEP
, NF1
),
102 /* GPP_I0 DDPB_HPD0 */ PAD_CFG_NF(GPP_I0
, NATIVE
, DEEP
, NF1
),
103 /* GPP_I1 DDPB_HPD1 */ PAD_CFG_NF(GPP_I1
, NATIVE
, DEEP
, NF1
),
104 /* GPP_I2 DDPB_HPD2 */ PAD_CFG_NF(GPP_I2
, NATIVE
, DEEP
, NF1
),
105 /* GPP_I3 DDPB_HPD3 */ PAD_CFG_NF(GPP_I3
, NONE
, DEEP
, NF1
),
106 /* GPP_I4 EDP_HPD */ PAD_CFG_NF(GPP_I4
, NONE
, DEEP
, NF1
),
107 /* GPP_I5 DDPB_CTRLCLK */ PAD_CFG_NF(GPP_I5
, NONE
, DEEP
, NF1
),
108 /* GPP_I6 DDPB_CTRLDATA */ PAD_CFG_NF(GPP_I6
, NONE
, DEEP
, NF1
),
109 /* GPP_I7 DDPC_CTRLCLK */ PAD_CFG_NF(GPP_I7
, NONE
, DEEP
, NF1
),
110 /* GPP_I8 DDPC_CTRLDATA */ PAD_CFG_NF(GPP_I8
, NONE
, DEEP
, NF1
),
111 /* GPP_I9 DDPD_CTRLCLK */ PAD_CFG_NF(GPP_I9
, DN_20K
, DEEP
, NF1
),
112 /* GPP_I10 DDPD_CTRLDATA */ PAD_CFG_NF(GPP_I10
, DN_20K
, DEEP
, NF1
),
113 /* GPP_J2 n/a */ PAD_CFG_NF(GPP_J2
, NONE
, DEEP
, NF1
),
114 /* GPP_J3 n/a */ PAD_CFG_NF(GPP_J3
, NONE
, DEEP
, NF1
),
115 /* GPP_J4 CNV_BRI_DT */ PAD_CFG_NF(GPP_J4
, NONE
, DEEP
, NF1
),
116 /* GPP_J5 CNV_BRI_RSP */ PAD_CFG_NF(GPP_J5
, NONE
, DEEP
, NF1
),
117 /* GPP_J6 CNV_RGI_DT */ PAD_CFG_NF(GPP_J6
, NONE
, DEEP
, NF1
),
118 /* GPP_J7 CNV_RGI_RSP */ PAD_CFG_NF(GPP_J7
, NONE
, DEEP
, NF1
),
119 /* GPP_J8 CNV_MFUART2_RXD */ PAD_CFG_NF(GPP_J8
, NONE
, DEEP
, NF1
),
120 /* GPP_J9 CNV_MFUART2_TXD */ PAD_CFG_NF(GPP_J9
, NONE
, DEEP
, NF1
),
121 /* GPP_J10 n/a */ PAD_CFG_NF(GPP_J10
, NONE
, DEEP
, NF1
),
122 /* GPP_J11 A4WP_PRESENT */ PAD_CFG_NF(GPP_J11
, NONE
, DEEP
, NF1
),
125 void variant_configure_gpios(void)
127 gpio_configure_pads(gpio_table
, ARRAY_SIZE(gpio_table
));