]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - src/arm/s5pv210-fascinate4g.dts
Import DTS from Linux 5.8
[FreeBSD/FreeBSD.git] / src / arm / s5pv210-fascinate4g.dts
1 // SPDX-License-Identifier: GPL-2.0
2
3 /dts-v1/;
4 #include <dt-bindings/gpio/gpio.h>
5 #include <dt-bindings/input/input.h>
6 #include "s5pv210-aries.dtsi"
7
8 / {
9         model = "Samsung Galaxy S Fascinate 4G (SGH-T959P) based on S5PV210";
10         compatible = "samsung,fascinate4g", "samsung,aries", "samsung,s5pv210";
11
12         chosen {
13                 stdout-path = &uart2;
14         };
15
16         gpio-keys {
17                 compatible = "gpio-keys";
18
19                 power {
20                         label = "power";
21                         gpios = <&gph2 6 GPIO_ACTIVE_LOW>;
22                         linux,code = <KEY_POWER>;
23                         wakeup-source;
24                 };
25
26                 vol-down {
27                         label = "volume_down";
28                         gpios = <&gph3 2 GPIO_ACTIVE_LOW>;
29                         linux,code = <KEY_VOLUMEDOWN>;
30                 };
31
32                 vol-up {
33                         label = "volume_up";
34                         gpios = <&gph3 1 GPIO_ACTIVE_LOW>;
35                         linux,code = <KEY_VOLUMEUP>;
36                 };
37         };
38 };
39
40 &pinctrl0 {
41         pinctrl-names = "default";
42         pinctrl-0 = <&sleep_cfg>;
43
44         /* Based on vendor kernel v2.6.35.7 */
45         sleep_cfg: sleep-cfg {
46                 PIN_SLP(gpa0-0, PREV, NONE);
47                 PIN_SLP(gpa0-1, PREV, NONE);
48                 PIN_SLP(gpa0-2, PREV, NONE);
49                 PIN_SLP(gpa0-3, OUT1, NONE);
50                 PIN_SLP(gpa0-4, PREV, NONE);
51                 PIN_SLP(gpa0-5, PREV, NONE);
52                 PIN_SLP(gpa0-6, PREV, NONE);
53                 PIN_SLP(gpa0-7, PREV, NONE);
54
55                 PIN_SLP(gpa1-0, INPUT, DOWN);
56                 PIN_SLP(gpa1-1, OUT0, NONE);
57                 PIN_SLP(gpa1-2, INPUT, DOWN);
58                 PIN_SLP(gpa1-3, OUT0, NONE);
59
60                 PIN_SLP(gpb-0, OUT0, NONE);
61                 PIN_SLP(gpb-1, OUT1, NONE);
62                 PIN_SLP(gpb-2, OUT0, NONE);
63                 PIN_SLP(gpb-3, PREV, NONE);
64                 PIN_SLP(gpb-4, INPUT, NONE);
65                 PIN_SLP(gpb-5, PREV, NONE);
66                 PIN_SLP(gpb-6, INPUT, DOWN);
67                 PIN_SLP(gpb-7, OUT0, NONE);
68
69                 PIN_SLP(gpc0-0, OUT0, NONE);
70                 PIN_SLP(gpc0-1, INPUT, DOWN);
71                 PIN_SLP(gpc0-2, OUT0, NONE);
72                 PIN_SLP(gpc0-3, INPUT, DOWN);
73                 PIN_SLP(gpc0-4, OUT0, NONE);
74
75                 PIN_SLP(gpc1-0, INPUT, DOWN);
76                 PIN_SLP(gpc1-1, INPUT, DOWN);
77                 PIN_SLP(gpc1-2, INPUT, DOWN);
78                 PIN_SLP(gpc1-3, INPUT, DOWN);
79                 PIN_SLP(gpc1-4, INPUT, DOWN);
80
81                 PIN_SLP(gpd0-0, INPUT, DOWN);
82                 PIN_SLP(gpd0-1, OUT0, NONE);
83                 PIN_SLP(gpd0-2, INPUT, DOWN);
84                 PIN_SLP(gpd0-3, INPUT, DOWN);
85
86                 PIN_SLP(gpd1-0, INPUT, NONE);
87                 PIN_SLP(gpd1-1, INPUT, NONE);
88                 PIN_SLP(gpd1-2, INPUT, DOWN);
89                 PIN_SLP(gpd1-3, INPUT, DOWN);
90                 PIN_SLP(gpd1-4, INPUT, DOWN);
91                 PIN_SLP(gpd1-5, INPUT, DOWN);
92
93                 PIN_SLP(gpe0-0, INPUT, DOWN);
94                 PIN_SLP(gpe0-1, INPUT, DOWN);
95                 PIN_SLP(gpe0-2, INPUT, DOWN);
96                 PIN_SLP(gpe0-3, INPUT, DOWN);
97                 PIN_SLP(gpe0-4, INPUT, DOWN);
98                 PIN_SLP(gpe0-5, INPUT, DOWN);
99                 PIN_SLP(gpe0-6, INPUT, DOWN);
100                 PIN_SLP(gpe0-7, INPUT, DOWN);
101
102                 PIN_SLP(gpe1-0, INPUT, DOWN);
103                 PIN_SLP(gpe1-1, INPUT, DOWN);
104                 PIN_SLP(gpe1-2, INPUT, DOWN);
105                 PIN_SLP(gpe1-3, OUT0, NONE);
106                 PIN_SLP(gpe1-4, INPUT, DOWN);
107
108                 PIN_SLP(gpf0-0, OUT0, NONE);
109                 PIN_SLP(gpf0-1, OUT0, NONE);
110                 PIN_SLP(gpf0-2, OUT0, NONE);
111                 PIN_SLP(gpf0-3, OUT0, NONE);
112                 PIN_SLP(gpf0-4, OUT0, NONE);
113                 PIN_SLP(gpf0-5, OUT0, NONE);
114                 PIN_SLP(gpf0-6, OUT0, NONE);
115                 PIN_SLP(gpf0-7, OUT0, NONE);
116
117                 PIN_SLP(gpf1-0, OUT0, NONE);
118                 PIN_SLP(gpf1-1, OUT0, NONE);
119                 PIN_SLP(gpf1-2, OUT0, NONE);
120                 PIN_SLP(gpf1-3, OUT0, NONE);
121                 PIN_SLP(gpf1-4, OUT0, NONE);
122                 PIN_SLP(gpf1-5, OUT0, NONE);
123                 PIN_SLP(gpf1-6, OUT0, NONE);
124                 PIN_SLP(gpf1-7, OUT0, NONE);
125
126                 PIN_SLP(gpf2-0, OUT0, NONE);
127                 PIN_SLP(gpf2-1, OUT0, NONE);
128                 PIN_SLP(gpf2-2, OUT0, NONE);
129                 PIN_SLP(gpf2-3, OUT0, NONE);
130                 PIN_SLP(gpf2-4, OUT0, NONE);
131                 PIN_SLP(gpf2-5, OUT0, NONE);
132                 PIN_SLP(gpf2-6, OUT0, NONE);
133                 PIN_SLP(gpf2-7, OUT0, NONE);
134
135                 PIN_SLP(gpf3-0, OUT0, NONE);
136                 PIN_SLP(gpf3-1, OUT0, NONE);
137                 PIN_SLP(gpf3-2, OUT0, NONE);
138                 PIN_SLP(gpf3-3, OUT0, NONE);
139                 PIN_SLP(gpf3-4, PREV, NONE);
140                 PIN_SLP(gpf3-5, INPUT, DOWN);
141
142                 PIN_SLP(gpg0-0, INPUT, DOWN);
143                 PIN_SLP(gpg0-1, INPUT, DOWN);
144                 PIN_SLP(gpg0-2, INPUT, NONE);
145                 PIN_SLP(gpg0-3, INPUT, DOWN);
146                 PIN_SLP(gpg0-4, INPUT, DOWN);
147                 PIN_SLP(gpg0-5, INPUT, DOWN);
148                 PIN_SLP(gpg0-6, INPUT, DOWN);
149
150                 PIN_SLP(gpg1-0, OUT0, NONE);
151                 PIN_SLP(gpg1-1, OUT1, NONE);
152                 PIN_SLP(gpg1-2, PREV, NONE);
153                 PIN_SLP(gpg1-3, OUT1, NONE);
154                 PIN_SLP(gpg1-4, OUT1, NONE);
155                 PIN_SLP(gpg1-5, OUT1, NONE);
156                 PIN_SLP(gpg1-6, OUT1, NONE);
157
158                 PIN_SLP(gpg2-0, OUT0, NONE);
159                 PIN_SLP(gpg2-1, OUT0, NONE);
160                 PIN_SLP(gpg2-2, INPUT, NONE);
161                 PIN_SLP(gpg2-3, OUT0, NONE);
162                 PIN_SLP(gpg2-4, OUT0, NONE);
163                 PIN_SLP(gpg2-5, OUT0, NONE);
164                 PIN_SLP(gpg2-6, OUT0, NONE);
165
166                 PIN_SLP(gpg3-0, PREV, UP);
167                 PIN_SLP(gpg3-1, PREV, UP);
168                 PIN_SLP(gpg3-2, INPUT, NONE);
169                 PIN_SLP(gpg3-3, INPUT, DOWN);
170                 PIN_SLP(gpg3-4, OUT0, NONE);
171                 PIN_SLP(gpg3-5, OUT0, NONE);
172                 PIN_SLP(gpg3-6, INPUT, DOWN);
173
174                 PIN_SLP(gpi-0, PREV, NONE);
175                 PIN_SLP(gpi-1, INPUT, DOWN);
176                 PIN_SLP(gpi-2, PREV, NONE);
177                 PIN_SLP(gpi-3, PREV, NONE);
178                 PIN_SLP(gpi-4, PREV, NONE);
179                 PIN_SLP(gpi-5, INPUT, DOWN);
180                 PIN_SLP(gpi-6, INPUT, DOWN);
181
182                 PIN_SLP(gpj0-0, INPUT, NONE);
183                 PIN_SLP(gpj0-1, INPUT, NONE);
184                 PIN_SLP(gpj0-2, INPUT, NONE);
185                 PIN_SLP(gpj0-3, INPUT, NONE);
186                 PIN_SLP(gpj0-4, INPUT, NONE);
187                 PIN_SLP(gpj0-5, INPUT, DOWN);
188                 PIN_SLP(gpj0-6, OUT0, NONE);
189                 PIN_SLP(gpj0-7, INPUT, NONE);
190
191                 PIN_SLP(gpj1-0, OUT1, NONE);
192                 PIN_SLP(gpj1-1, OUT0, NONE);
193                 PIN_SLP(gpj1-2, INPUT, DOWN);
194                 PIN_SLP(gpj1-3, PREV, NONE);
195                 PIN_SLP(gpj1-4, PREV, NONE);
196                 PIN_SLP(gpj1-5, OUT0, NONE);
197
198                 PIN_SLP(gpj2-0, INPUT, DOWN);
199                 PIN_SLP(gpj2-1, INPUT, DOWN);
200                 PIN_SLP(gpj2-2, OUT0, NONE);
201                 PIN_SLP(gpj2-3, INPUT, DOWN);
202                 PIN_SLP(gpj2-4, INPUT, DOWN);
203                 PIN_SLP(gpj2-5, PREV, NONE);
204                 PIN_SLP(gpj2-6, PREV, NONE);
205                 PIN_SLP(gpj2-7, INPUT, DOWN);
206
207                 PIN_SLP(gpj3-0, INPUT, NONE);
208                 PIN_SLP(gpj3-1, INPUT, NONE);
209                 PIN_SLP(gpj3-2, OUT0, NONE);
210                 PIN_SLP(gpj3-3, INPUT, DOWN);
211                 PIN_SLP(gpj3-4, INPUT, NONE);
212                 PIN_SLP(gpj3-5, INPUT, NONE);
213                 PIN_SLP(gpj3-6, INPUT, NONE);
214                 PIN_SLP(gpj3-7, INPUT, NONE);
215
216                 PIN_SLP(gpj4-0, INPUT, NONE);
217                 PIN_SLP(gpj4-1, INPUT, DOWN);
218                 PIN_SLP(gpj4-2, PREV, NONE);
219                 PIN_SLP(gpj4-3, INPUT, NONE);
220                 PIN_SLP(gpj4-4, INPUT, DOWN);
221
222                 PIN_SLP(mp01-0, OUT1, NONE);
223                 PIN_SLP(mp01-1, OUT0, NONE);
224                 PIN_SLP(mp01-2, INPUT, DOWN);
225                 PIN_SLP(mp01-3, INPUT, DOWN);
226                 PIN_SLP(mp01-4, OUT1, NONE);
227                 PIN_SLP(mp01-5, INPUT, DOWN);
228                 PIN_SLP(mp01-6, INPUT, DOWN);
229                 PIN_SLP(mp01-7, INPUT, DOWN);
230
231                 PIN_SLP(mp02-0, INPUT, DOWN);
232                 PIN_SLP(mp02-1, INPUT, DOWN);
233                 PIN_SLP(mp02-2, INPUT, NONE);
234                 PIN_SLP(mp02-3, INPUT, DOWN);
235
236                 PIN_SLP(mp03-0, INPUT, DOWN);
237                 PIN_SLP(mp03-1, INPUT, DOWN);
238                 PIN_SLP(mp03-2, OUT1, NONE);
239                 PIN_SLP(mp03-3, OUT0, NONE);
240                 PIN_SLP(mp03-4, INPUT, NONE);
241                 PIN_SLP(mp03-5, OUT0, NONE);
242                 PIN_SLP(mp03-6, INPUT, DOWN);
243                 PIN_SLP(mp03-7, INPUT, DOWN);
244
245                 PIN_SLP(mp04-0, INPUT, DOWN);
246                 PIN_SLP(mp04-1, OUT0, NONE);
247                 PIN_SLP(mp04-2, INPUT, DOWN);
248                 PIN_SLP(mp04-3, OUT0, NONE);
249                 PIN_SLP(mp04-4, INPUT, DOWN);
250                 PIN_SLP(mp04-5, INPUT, DOWN);
251                 PIN_SLP(mp04-6, OUT0, NONE);
252                 PIN_SLP(mp04-7, INPUT, DOWN);
253
254                 PIN_SLP(mp05-0, INPUT, NONE);
255                 PIN_SLP(mp05-1, INPUT, NONE);
256                 PIN_SLP(mp05-2, INPUT, NONE);
257                 PIN_SLP(mp05-3, INPUT, NONE);
258                 PIN_SLP(mp05-4, INPUT, DOWN);
259                 PIN_SLP(mp05-5, OUT0, NONE);
260                 PIN_SLP(mp05-6, INPUT, DOWN);
261                 PIN_SLP(mp05-7, PREV, NONE);
262
263                 PIN_SLP(mp06-0, INPUT, DOWN);
264                 PIN_SLP(mp06-1, INPUT, DOWN);
265                 PIN_SLP(mp06-2, INPUT, DOWN);
266                 PIN_SLP(mp06-3, INPUT, DOWN);
267                 PIN_SLP(mp06-4, INPUT, DOWN);
268                 PIN_SLP(mp06-5, INPUT, DOWN);
269                 PIN_SLP(mp06-6, INPUT, DOWN);
270                 PIN_SLP(mp06-7, INPUT, DOWN);
271
272                 PIN_SLP(mp07-0, INPUT, DOWN);
273                 PIN_SLP(mp07-1, INPUT, DOWN);
274                 PIN_SLP(mp07-2, INPUT, DOWN);
275                 PIN_SLP(mp07-3, INPUT, DOWN);
276                 PIN_SLP(mp07-4, INPUT, DOWN);
277                 PIN_SLP(mp07-5, INPUT, DOWN);
278                 PIN_SLP(mp07-6, INPUT, DOWN);
279                 PIN_SLP(mp07-7, INPUT, DOWN);
280         };
281 };
282
283 &wm8994 {
284         /* GPIO3 (BCLK2) and GPIO4 (LRCLK2) as outputs */
285         wlf,gpio-cfg = <0xa101 0x8100 0x8100 0x8100 0x8100 0xa101
286                         0x0100 0x8100 0x0100 0x0100 0x0100>;
287 };