]> git.ipfire.org Git - people/ms/u-boot.git/blame - arch/sandbox/dts/sandbox.dts
sandbox: Rename 'num-gpios' property to avoid dtc warning
[people/ms/u-boot.git] / arch / sandbox / dts / sandbox.dts
CommitLineData
714a5621
SG
1/dts-v1/;
2
4c3db41a
SG
3#define USB_CLASS_HUB 9
4
714a5621 5/ {
0b304a24 6 #address-cells = <1>;
20806e74 7 #size-cells = <1>;
d63b5b4f 8 model = "sandbox";
0b304a24 9
9569c406 10 aliases {
22f68524 11 eth5 = "/eth@90000000";
46af3608 12 i2c0 = &i2c_0;
9569c406 13 pci0 = &pci;
46af3608 14 rtc0 = &rtc_0;
9569c406
SG
15 };
16
2a9ae6e0
SG
17 chosen {
18 stdout-path = "/serial";
19 };
20
3fbb7871
SG
21 cros_ec: cros-ec@0 {
22 reg = <0 0>;
23 compatible = "google,cros-ec-sandbox";
39741c01 24
3fbb7871
SG
25 /*
26 * This describes the flash memory within the EC. Note
27 * that the STM32L flash erases to 0, not 0xff.
28 */
29 #address-cells = <1>;
30 #size-cells = <1>;
31 flash@8000000 {
32 reg = <0x08000000 0x20000>;
33 erase-value = <0>;
39741c01
SG
34 #address-cells = <1>;
35 #size-cells = <1>;
3fbb7871
SG
36
37 /* Information for sandbox */
38 ro {
39 reg = <0 0xf000>;
40 };
41 wp-ro {
42 reg = <0xf000 0x1000>;
43 };
44 rw {
45 reg = <0x10000 0x10000>;
39741c01
SG
46 };
47 };
48 };
49
f4d84576
SG
50 eth@10002000 {
51 compatible = "sandbox,eth";
52 reg = <0x10002000 0x1000>;
53 fake-host-hwaddr = [00 00 66 44 22 00];
54 };
55
56 eth@80000000 {
57 compatible = "sandbox,eth-raw";
58 reg = <0x80000000 0x1000>;
59 host-raw-interface = "eth0";
60 };
61
62 eth@90000000 {
63 compatible = "sandbox,eth-raw";
64 reg = <0x90000000 0x1000>;
65 host-raw-interface = "lo";
39741c01
SG
66 };
67
a02af4ae 68 gpio_a: gpios@0 {
4bc9a193
SG
69 gpio-controller;
70 compatible = "sandbox,gpio";
71 #gpio-cells = <1>;
72 gpio-bank-name = "a";
995b60b5 73 sandbox,gpio-count = <20>;
4bc9a193
SG
74 };
75
a02af4ae
SG
76 gpio_b: gpios@1 {
77 gpio-controller;
78 compatible = "sandbox,gpio";
79 #gpio-cells = <2>;
80 gpio-bank-name = "b";
995b60b5 81 sandbox,gpio-count = <10>;
a02af4ae
SG
82 };
83
f4d84576
SG
84 hexagon {
85 compatible = "demo-simple";
86 colour = "white";
87 sides = <6>;
88 };
89
46af3608 90 i2c_0: i2c@0 {
776f96f5
SG
91 #address-cells = <1>;
92 #size-cells = <0>;
20806e74 93 reg = <0 0>;
776f96f5
SG
94 compatible = "sandbox,i2c";
95 clock-frequency = <400000>;
9c6a3c67
MY
96 pinctrl-names = "default";
97 pinctrl-0 = <&pinctrl_i2c0>;
776f96f5
SG
98 eeprom@2c {
99 reg = <0x2c>;
100 compatible = "i2c-eeprom";
101 emul {
102 compatible = "sandbox,i2c-eeprom";
103 sandbox,filename = "i2c.bin";
104 sandbox,size = <128>;
105 };
106 };
46af3608
SG
107
108 rtc_0: rtc@43 {
109 reg = <0x43>;
110 compatible = "sandbox-rtc";
111 emul {
112 compatible = "sandbox,i2c-rtc";
113 };
114 };
9038cd53
PM
115 sandbox_pmic: sandbox_pmic {
116 reg = <0x40>;
117 };
776f96f5
SG
118 };
119
f4d84576 120 lcd {
3ade5bc4 121 u-boot,dm-pre-reloc;
f4d84576
SG
122 compatible = "sandbox,lcd-sdl";
123 xres = <1366>;
124 yres = <768>;
0b304a24
SG
125 };
126
a89c3a04
SG
127 leds {
128 compatible = "gpio-leds";
129
130 iracibble {
131 gpios = <&gpio_a 1 0>;
132 label = "sandbox:red";
133 };
134
135 martinet {
136 gpios = <&gpio_a 2 0>;
137 label = "sandbox:green";
138 };
139 };
140
9569c406
SG
141 pci: pci-controller {
142 compatible = "sandbox,pci";
143 device_type = "pci";
144 #address-cells = <3>;
145 #size-cells = <2>;
146 ranges = <0x02000000 0 0x10000000 0x10000000 0 0x2000
147 0x01000000 0 0x20000000 0x20000000 0 0x2000>;
148 pci@1f,0 {
149 compatible = "pci-generic";
150 reg = <0xf800 0 0 0 0>;
151 emul@1f,0 {
152 compatible = "sandbox,swap-case";
153 };
154 };
155 };
156
9c6a3c67
MY
157 pinctrl {
158 compatible = "sandbox,pinctrl";
159
160 pinctrl_i2c0: i2c0 {
161 groups = "i2c";
162 function = "i2c";
163 bias-pull-up;
164 };
165
166 pinctrl_serial0: uart0 {
167 groups = "serial_a";
168 function = "serial";
169 };
170 };
171
7bb91dd1
SG
172 reset@1 {
173 compatible = "sandbox,reset";
174 };
175
f4d84576
SG
176 spi@0 {
177 #address-cells = <1>;
178 #size-cells = <0>;
179 reg = <0 0>;
180 compatible = "sandbox,spi";
181 cs-gpios = <0>, <&gpio_a 0>;
182 firmware_storage_spi: flash@0 {
183 reg = <0>;
184 compatible = "spansion,m25p16", "sandbox,spi-flash";
185 spi-max-frequency = <40000000>;
186 sandbox,filename = "spi.bin";
187 };
3ea143ab 188 };
a346ca79 189
a091a8f0
SG
190 spl-test {
191 u-boot,dm-pre-reloc;
192 compatible = "sandbox,spl-test";
193 boolval;
194 intval = <1>;
195 intarray = <2 3 4>;
196 byteval = [05];
197 bytearray = [06];
198 longbytearray = [09 0a 0b 0c 0d 0e 0f 10 11];
199 stringval = "message";
200 stringarray = "multi-word", "message";
201 };
202
203 spl-test2 {
204 u-boot,dm-pre-reloc;
205 compatible = "sandbox,spl-test";
206 intval = <3>;
207 intarray = <5>;
208 byteval = [08];
209 bytearray = [01 23 34];
210 longbytearray = [09 0a 0b 0c];
211 stringval = "message2";
212 stringarray = "another", "multi-word", "message";
213 };
214
215 spl-test3 {
216 u-boot,dm-pre-reloc;
217 compatible = "sandbox,spl-test";
218 stringarray = "one";
219 };
220
6b6024a3
SG
221 spl-test4 {
222 u-boot,dm-pre-reloc;
223 compatible = "sandbox,spl-test.2";
224 };
225
f4d84576
SG
226 square {
227 compatible = "demo-shape";
228 colour = "blue";
229 sides = <4>;
a346ca79 230 };
22f68524 231
9961a0b6
TC
232 timer {
233 compatible = "sandbox,timer";
f838f124 234 clock-frequency = <1000000>;
9961a0b6
TC
235 };
236
21baf15b
SG
237 tpm {
238 compatible = "google,sandbox-tpm";
239 };
240
f4d84576
SG
241 triangle {
242 compatible = "demo-shape";
243 colour = "cyan";
244 sides = <3>;
245 character = <83>;
246 light-gpios = <&gpio_a 2>, <&gpio_b 6 0>;
247 };
248
249 /* Needs to be available prior to relocation */
250 uart0: serial {
251 compatible = "sandbox,serial";
252 sandbox,text-colour = "cyan";
9c6a3c67
MY
253 pinctrl-names = "default";
254 pinctrl-0 = <&pinctrl_serial0>;
22f68524 255 };
4c3db41a
SG
256
257 usb@0 {
258 compatible = "sandbox,usb";
259 status = "disabled";
260 hub {
261 compatible = "sandbox,usb-hub";
262 #address-cells = <1>;
263 #size-cells = <0>;
264 flash-stick {
265 reg = <0>;
266 compatible = "sandbox,usb-flash";
267 };
268 };
269 };
270
271 usb@1 {
272 compatible = "sandbox,usb";
273 hub {
274 compatible = "usb-hub";
275 usb,device-class = <USB_CLASS_HUB>;
276 hub-emul {
277 compatible = "sandbox,usb-hub";
278 #address-cells = <1>;
279 #size-cells = <0>;
280 flash-stick {
281 reg = <0>;
282 compatible = "sandbox,usb-flash";
283 sandbox,filepath = "flash.bin";
284 };
285 };
286 };
287 };
288
289 usb@2 {
290 compatible = "sandbox,usb";
291 status = "disabled";
292 };
293
d33776e4
MK
294 spmi: spmi@0 {
295 compatible = "sandbox,spmi";
296 #address-cells = <0x1>;
297 #size-cells = <0x1>;
298 pm8916@0 {
299 compatible = "qcom,spmi-pmic";
300 reg = <0x0 0x1>;
301 #address-cells = <0x1>;
302 #size-cells = <0x1>;
303
304 spmi_gpios: gpios@c000 {
305 compatible = "qcom,pm8916-gpio";
306 reg = <0xc000 0x400>;
307 gpio-controller;
308 gpio-count = <4>;
309 #gpio-cells = <2>;
310 gpio-bank-name="spmi";
311 };
312 };
313 };
714a5621 314};
3fbb7871
SG
315
316#include "cros-ec-keyboard.dtsi"
9038cd53 317#include "sandbox_pmic.dtsi"