]> git.ipfire.org Git - people/ms/u-boot.git/blame - arch/sandbox/dts/test.dts
dm: sandbox: pwm: Add a basic pwm test
[people/ms/u-boot.git] / arch / sandbox / dts / test.dts
CommitLineData
2e7d35d2
SG
1/dts-v1/;
2
3/ {
4 model = "sandbox";
5 compatible = "sandbox";
6 #address-cells = <1>;
0503e820 7 #size-cells = <1>;
2e7d35d2 8
00606d7e
SG
9 aliases {
10 console = &uart0;
171e991d 11 eth0 = "/eth@10002000";
71d7971f 12 eth3 = &eth_3;
171e991d 13 eth5 = &eth_5;
9cc36a2b 14 i2c0 = "/i2c@0";
f64000c3 15 pci0 = &pci;
5215940f
NM
16 remoteproc1 = &rproc_1;
17 remoteproc2 = &rproc_2;
52d3bc5d
SG
18 rtc0 = &rtc_0;
19 rtc1 = &rtc_1;
171e991d 20 spi0 = "/spi@0";
f64000c3 21 testfdt6 = "/e-test";
9cc36a2b
SG
22 testbus3 = "/some-bus";
23 testfdt0 = "/some-bus/c-test@0";
24 testfdt1 = "/some-bus/c-test@1";
25 testfdt3 = "/b-test";
26 testfdt5 = "/some-bus/c-test@5";
27 testfdt8 = "/a-test";
e00cb223
SG
28 usb0 = &usb_0;
29 usb1 = &usb_1;
30 usb2 = &usb_2;
00606d7e
SG
31 };
32
2e7d35d2 33 a-test {
0503e820 34 reg = <0 1>;
2e7d35d2 35 compatible = "denx,u-boot-fdt-test";
eb9ef5fe 36 ping-expect = <0>;
2e7d35d2 37 ping-add = <0>;
00606d7e 38 u-boot,dm-pre-reloc;
3669e0e7
SG
39 test-gpios = <&gpio_a 1>, <&gpio_a 4>, <&gpio_b 5 0 3 2 1>,
40 <0>, <&gpio_a 12>;
41 test2-gpios = <&gpio_a 1>, <&gpio_a 4>, <&gpio_b 6 1 3 2 1>,
42 <&gpio_b 7 2 3 2 1>, <&gpio_b 8 4 3 2 1>,
43 <&gpio_b 9 0xc 3 2 1>;
2e7d35d2
SG
44 };
45
46 junk {
0503e820 47 reg = <1 1>;
2e7d35d2
SG
48 compatible = "not,compatible";
49 };
50
51 no-compatible {
0503e820 52 reg = <2 1>;
2e7d35d2
SG
53 };
54
55 b-test {
0503e820 56 reg = <3 1>;
2e7d35d2 57 compatible = "denx,u-boot-fdt-test";
eb9ef5fe 58 ping-expect = <3>;
2e7d35d2
SG
59 ping-add = <3>;
60 };
61
62 some-bus {
63 #address-cells = <1>;
64 #size-cells = <0>;
1ca7e206 65 compatible = "denx,u-boot-test-bus";
0503e820 66 reg = <3 1>;
eb9ef5fe 67 ping-expect = <4>;
2e7d35d2 68 ping-add = <4>;
1ca7e206 69 c-test@5 {
2e7d35d2
SG
70 compatible = "denx,u-boot-fdt-test";
71 reg = <5>;
1ca7e206 72 ping-expect = <5>;
2e7d35d2
SG
73 ping-add = <5>;
74 };
1ca7e206
SG
75 c-test@0 {
76 compatible = "denx,u-boot-fdt-test";
77 reg = <0>;
78 ping-expect = <6>;
79 ping-add = <6>;
80 };
81 c-test@1 {
82 compatible = "denx,u-boot-fdt-test";
83 reg = <1>;
84 ping-expect = <7>;
85 ping-add = <7>;
86 };
2e7d35d2
SG
87 };
88
89 d-test {
0503e820 90 reg = <3 1>;
5a66a8ff
SG
91 ping-expect = <6>;
92 ping-add = <6>;
93 compatible = "google,another-fdt-test";
94 };
95
96 e-test {
0503e820 97 reg = <3 1>;
eb9ef5fe 98 ping-expect = <6>;
2e7d35d2
SG
99 ping-add = <6>;
100 compatible = "google,another-fdt-test";
101 };
102
9cc36a2b
SG
103 f-test {
104 compatible = "denx,u-boot-fdt-test";
105 };
106
107 g-test {
108 compatible = "denx,u-boot-fdt-test";
109 };
110
135aa950
SW
111 clk_fixed: clk-fixed {
112 compatible = "fixed-clock";
113 #clock-cells = <0>;
114 clock-frequency = <1234>;
115 };
116
117 clk_sandbox: clk-sbox {
6a1c7cef 118 compatible = "sandbox,clk";
135aa950
SW
119 #clock-cells = <1>;
120 };
121
122 clk-test {
123 compatible = "sandbox,clk-test";
124 clocks = <&clk_fixed>,
125 <&clk_sandbox 1>,
126 <&clk_sandbox 0>;
127 clock-names = "fixed", "i2c", "spi";
6a1c7cef
SG
128 };
129
171e991d
SG
130 eth@10002000 {
131 compatible = "sandbox,eth";
132 reg = <0x10002000 0x1000>;
133 fake-host-hwaddr = <0x00 0x00 0x66 0x44 0x22 0x00>;
134 };
135
136 eth_5: eth@10003000 {
137 compatible = "sandbox,eth";
138 reg = <0x10003000 0x1000>;
139 fake-host-hwaddr = <0x00 0x00 0x66 0x44 0x22 0x11>;
140 };
141
71d7971f
BM
142 eth_3: sbe5 {
143 compatible = "sandbox,eth";
144 reg = <0x10005000 0x1000>;
145 fake-host-hwaddr = <0x00 0x00 0x66 0x44 0x22 0x33>;
146 };
147
171e991d
SG
148 eth@10004000 {
149 compatible = "sandbox,eth";
150 reg = <0x10004000 0x1000>;
151 fake-host-hwaddr = <0x00 0x00 0x66 0x44 0x22 0x22>;
152 };
153
0ae0cb7b 154 gpio_a: base-gpios {
2e7d35d2 155 compatible = "sandbox,gpio";
3669e0e7
SG
156 gpio-controller;
157 #gpio-cells = <1>;
2e7d35d2
SG
158 gpio-bank-name = "a";
159 num-gpios = <20>;
160 };
161
3669e0e7 162 gpio_b: extra-gpios {
2e7d35d2 163 compatible = "sandbox,gpio";
3669e0e7
SG
164 gpio-controller;
165 #gpio-cells = <5>;
2e7d35d2
SG
166 gpio-bank-name = "b";
167 num-gpios = <10>;
168 };
0ae0cb7b 169
ecc2ed55
SG
170 i2c@0 {
171 #address-cells = <1>;
172 #size-cells = <0>;
0503e820 173 reg = <0 1>;
ecc2ed55
SG
174 compatible = "sandbox,i2c";
175 clock-frequency = <100000>;
176 eeprom@2c {
177 reg = <0x2c>;
178 compatible = "i2c-eeprom";
179 emul {
180 compatible = "sandbox,i2c-eeprom";
181 sandbox,filename = "i2c.bin";
182 sandbox,size = <256>;
183 };
184 };
9038cd53 185
52d3bc5d
SG
186 rtc_0: rtc@43 {
187 reg = <0x43>;
188 compatible = "sandbox-rtc";
189 emul {
190 compatible = "sandbox,i2c-rtc";
191 };
192 };
193
194 rtc_1: rtc@61 {
195 reg = <0x61>;
196 compatible = "sandbox-rtc";
197 emul {
198 compatible = "sandbox,i2c-rtc";
199 };
200 };
201
9038cd53
PM
202 sandbox_pmic: sandbox_pmic {
203 reg = <0x40>;
204 };
ecc2ed55
SG
205 };
206
08d6300a
PM
207 adc@0 {
208 compatible = "sandbox,adc";
209 vdd-supply = <&buck2>;
210 vss-microvolts = <0>;
211 };
212
3c97c4fb
SG
213 lcd {
214 u-boot,dm-pre-reloc;
215 compatible = "sandbox,lcd-sdl";
216 xres = <1366>;
217 yres = <768>;
218 };
219
3c43fba3
SG
220 leds {
221 compatible = "gpio-leds";
222
223 iracibble {
224 gpios = <&gpio_a 1 0>;
225 label = "sandbox:red";
226 };
227
228 martinet {
229 gpios = <&gpio_a 2 0>;
230 label = "sandbox:green";
231 };
232 };
233
8961b524
SW
234 mbox: mbox {
235 compatible = "sandbox,mbox";
236 #mbox-cells = <1>;
237 };
238
239 mbox-test {
240 compatible = "sandbox,mbox-test";
241 mboxes = <&mbox 100>, <&mbox 1>;
242 mbox-names = "other", "test";
243 };
244
8e6cc461
SG
245 mmc {
246 compatible = "sandbox,mmc";
247 };
248
d3b7ff14
SG
249 pci: pci-controller {
250 compatible = "sandbox,pci";
251 device_type = "pci";
252 #address-cells = <3>;
253 #size-cells = <2>;
254 ranges = <0x02000000 0 0x10000000 0x10000000 0 0x2000
255 0x01000000 0 0x20000000 0x20000000 0 0x2000>;
256 pci@1f,0 {
257 compatible = "pci-generic";
258 reg = <0xf800 0 0 0 0>;
259 emul@1f,0 {
260 compatible = "sandbox,swap-case";
261 };
262 };
263 };
264
61f5ddcb
SW
265 pwrdom: power-domain {
266 compatible = "sandbox,power-domain";
267 #power-domain-cells = <1>;
268 };
269
270 power-domain-test {
271 compatible = "sandbox,power-domain-test";
272 power-domains = <&pwrdom 2>;
273 };
274
43b41566
SG
275 pwm {
276 compatible = "sandbox,pwm";
277 };
278
279 pwm2 {
280 compatible = "sandbox,pwm";
281 };
282
64ce0cad
SG
283 ram {
284 compatible = "sandbox,ram";
285 };
286
5010d98f
SG
287 reset@0 {
288 compatible = "sandbox,warm-reset";
289 };
290
291 reset@1 {
292 compatible = "sandbox,reset";
293 };
294
4581b717
SW
295 resetc: reset-ctl {
296 compatible = "sandbox,reset-ctl";
297 #reset-cells = <1>;
298 };
299
300 reset-ctl-test {
301 compatible = "sandbox,reset-ctl-test";
302 resets = <&resetc 100>, <&resetc 2>;
303 reset-names = "other", "test";
304 };
305
5215940f
NM
306 rproc_1: rproc@1 {
307 compatible = "sandbox,test-processor";
308 remoteproc-name = "remoteproc-test-dev1";
309 };
310
311 rproc_2: rproc@2 {
312 compatible = "sandbox,test-processor";
313 internal-memory-mapped;
314 remoteproc-name = "remoteproc-test-dev2";
315 };
316
0ae0cb7b
SG
317 spi@0 {
318 #address-cells = <1>;
319 #size-cells = <0>;
0503e820 320 reg = <0 1>;
0ae0cb7b
SG
321 compatible = "sandbox,spi";
322 cs-gpios = <0>, <&gpio_a 0>;
323 spi.bin@0 {
324 reg = <0>;
325 compatible = "spansion,m25p16", "spi-flash";
326 spi-max-frequency = <40000000>;
327 sandbox,filename = "spi.bin";
328 };
329 };
330
04035fd3
SG
331 syscon@0 {
332 compatible = "sandbox,syscon0";
0503e820 333 reg = <0x10 4>;
04035fd3
SG
334 };
335
336 syscon@1 {
337 compatible = "sandbox,syscon1";
0503e820
SG
338 reg = <0x20 5
339 0x28 6
340 0x30 7
341 0x38 8>;
04035fd3
SG
342 };
343
e7cc8d11
TC
344 timer {
345 compatible = "sandbox,timer";
346 clock-frequency = <1000000>;
347 };
348
171e991d
SG
349 uart0: serial {
350 compatible = "sandbox,serial";
351 u-boot,dm-pre-reloc;
bfacad7d
JH
352 };
353
e00cb223
SG
354 usb_0: usb@0 {
355 compatible = "sandbox,usb";
356 status = "disabled";
357 hub {
358 compatible = "sandbox,usb-hub";
359 #address-cells = <1>;
360 #size-cells = <0>;
361 flash-stick {
362 reg = <0>;
363 compatible = "sandbox,usb-flash";
364 };
365 };
366 };
367
368 usb_1: usb@1 {
369 compatible = "sandbox,usb";
370 hub {
371 compatible = "usb-hub";
372 usb,device-class = <9>;
373 hub-emul {
374 compatible = "sandbox,usb-hub";
375 #address-cells = <1>;
376 #size-cells = <0>;
431cbd6d 377 flash-stick@0 {
e00cb223
SG
378 reg = <0>;
379 compatible = "sandbox,usb-flash";
380 sandbox,filepath = "testflash.bin";
381 };
382
431cbd6d
SG
383 flash-stick@1 {
384 reg = <1>;
385 compatible = "sandbox,usb-flash";
386 sandbox,filepath = "testflash1.bin";
387 };
388
389 flash-stick@2 {
390 reg = <2>;
391 compatible = "sandbox,usb-flash";
392 sandbox,filepath = "testflash2.bin";
393 };
394
bff1a71e
SG
395 keyb@3 {
396 reg = <3>;
397 compatible = "sandbox,usb-keyb";
398 };
399
e00cb223
SG
400 };
401 };
402 };
403
404 usb_2: usb@2 {
405 compatible = "sandbox,usb";
406 status = "disabled";
407 };
408
d33776e4
MK
409 spmi: spmi@0 {
410 compatible = "sandbox,spmi";
411 #address-cells = <0x1>;
412 #size-cells = <0x1>;
413 pm8916@0 {
414 compatible = "qcom,spmi-pmic";
415 reg = <0x0 0x1>;
416 #address-cells = <0x1>;
417 #size-cells = <0x1>;
418
419 spmi_gpios: gpios@c000 {
420 compatible = "qcom,pm8916-gpio";
421 reg = <0xc000 0x400>;
422 gpio-controller;
423 gpio-count = <4>;
424 #gpio-cells = <2>;
425 gpio-bank-name="spmi";
426 };
427 };
428 };
2e7d35d2 429};
9038cd53
PM
430
431#include "sandbox_pmic.dtsi"