blob: a3c95f2cdb2173899dd250f34c86df2a2e340d6a [file] [log] [blame]
Mario Six61efece2018-02-12 08:05:57 +01001/dts-v1/;
2
3#define USB_CLASS_HUB 9
4
5/ {
6 #address-cells = <2>;
7 #size-cells = <2>;
8 model = "sandbox";
9
10 aliases {
Mario Six61efece2018-02-12 08:05:57 +010011 i2c0 = &i2c_0;
12 pci0 = &pci;
13 rtc0 = &rtc_0;
14 };
15
16 chosen {
17 stdout-path = "/serial";
18 };
19
Simon Glass699c9ca2018-10-01 12:22:08 -060020 cros_ec: cros-ec {
Mario Six61efece2018-02-12 08:05:57 +010021 reg = <0 0 0 0>;
22 compatible = "google,cros-ec-sandbox";
23
24 /*
25 * This describes the flash memory within the EC. Note
26 * that the STM32L flash erases to 0, not 0xff.
27 */
Simon Glass699c9ca2018-10-01 12:22:08 -060028 flash {
29 image-pos = <0x08000000>;
30 size = <0x20000>;
Mario Six61efece2018-02-12 08:05:57 +010031 erase-value = <0>;
Mario Six61efece2018-02-12 08:05:57 +010032
33 /* Information for sandbox */
34 ro {
Simon Glass699c9ca2018-10-01 12:22:08 -060035 image-pos = <0>;
36 size = <0xf000>;
Mario Six61efece2018-02-12 08:05:57 +010037 };
38 wp-ro {
Simon Glass699c9ca2018-10-01 12:22:08 -060039 image-pos = <0xf000>;
40 size = <0x1000>;
Mario Six61efece2018-02-12 08:05:57 +010041 };
42 rw {
Simon Glass699c9ca2018-10-01 12:22:08 -060043 image-pos = <0x10000>;
44 size = <0x10000>;
Mario Six61efece2018-02-12 08:05:57 +010045 };
46 };
47 };
48
Joe Hershberger89590c82018-07-02 14:47:54 -050049 ethrawbus {
50 compatible = "sandbox,eth-raw-bus";
51 skip-localhost = <1>;
52 };
53
Mario Six61efece2018-02-12 08:05:57 +010054 eth@10002000 {
55 compatible = "sandbox,eth";
56 reg = <0x0 0x10002000 0x0 0x1000>;
57 fake-host-hwaddr = [00 00 66 44 22 00];
58 };
59
Mario Six61efece2018-02-12 08:05:57 +010060 gpio_a: gpios@0 {
61 gpio-controller;
62 compatible = "sandbox,gpio";
63 #gpio-cells = <1>;
64 gpio-bank-name = "a";
65 sandbox,gpio-count = <20>;
66 };
67
68 gpio_b: gpios@1 {
69 gpio-controller;
70 compatible = "sandbox,gpio";
71 #gpio-cells = <2>;
72 gpio-bank-name = "b";
73 sandbox,gpio-count = <10>;
74 };
75
76 hexagon {
77 compatible = "demo-simple";
78 colour = "white";
79 sides = <6>;
80 };
81
82 i2c_0: i2c@0 {
83 #address-cells = <1>;
84 #size-cells = <0>;
85 reg = <0 0 0 0>;
86 compatible = "sandbox,i2c";
87 clock-frequency = <400000>;
88 pinctrl-names = "default";
89 pinctrl-0 = <&pinctrl_i2c0>;
90 eeprom@2c {
91 reg = <0x2c>;
92 compatible = "i2c-eeprom";
Heinrich Schuchardt1b995362019-01-05 22:30:07 +010093 sandbox,emul = <&emul_eeprom>;
Mario Six61efece2018-02-12 08:05:57 +010094 };
95
96 rtc_0: rtc@43 {
97 reg = <0x43>;
98 compatible = "sandbox-rtc";
Heinrich Schuchardt1b995362019-01-05 22:30:07 +010099 sandbox,emul = <&emul0>;
Mario Six61efece2018-02-12 08:05:57 +0100100 };
101 sandbox_pmic: sandbox_pmic {
102 reg = <0x40>;
103 };
Lukasz Majewskia4d82972018-05-15 16:26:40 +0200104
105 mc34708: pmic@41 {
106 reg = <0x41>;
107 };
Simon Glass17b56f62018-11-18 08:14:34 -0700108
109 i2c_emul: emul {
110 reg = <0xff>;
111 compatible = "sandbox,i2c-emul-parent";
Heinrich Schuchardt1b995362019-01-05 22:30:07 +0100112 emul_eeprom: emul-eeprom {
Simon Glass17b56f62018-11-18 08:14:34 -0700113 compatible = "sandbox,i2c-eeprom";
114 sandbox,filename = "i2c.bin";
115 sandbox,size = <256>;
116 };
Heinrich Schuchardt1b995362019-01-05 22:30:07 +0100117 emul0: emul0 {
Simon Glass17b56f62018-11-18 08:14:34 -0700118 compatible = "sandbox,i2c-rtc";
119 };
120 };
Mario Six61efece2018-02-12 08:05:57 +0100121 };
122
123 lcd {
124 u-boot,dm-pre-reloc;
125 compatible = "sandbox,lcd-sdl";
126 xres = <1366>;
127 yres = <768>;
128 };
129
130 leds {
131 compatible = "gpio-leds";
132
133 iracibble {
134 gpios = <&gpio_a 1 0>;
135 label = "sandbox:red";
136 };
137
138 martinet {
139 gpios = <&gpio_a 2 0>;
140 label = "sandbox:green";
141 };
142 };
143
144 pci: pci-controller {
145 compatible = "sandbox,pci";
146 device_type = "pci";
147 #address-cells = <3>;
148 #size-cells = <2>;
149 ranges = <0x02000000 0 0x10000000 0 0x10000000 0 0x2000
150 0x01000000 0 0x20000000 0 0x20000000 0 0x2000>;
151 pci@1f,0 {
152 compatible = "pci-generic";
153 reg = <0xf800 0 0 0 0>;
154 emul@1f,0 {
155 compatible = "sandbox,swap-case";
156 };
157 };
158 };
159
160 pinctrl {
161 compatible = "sandbox,pinctrl";
162
163 pinctrl_i2c0: i2c0 {
164 groups = "i2c";
165 function = "i2c";
166 bias-pull-up;
167 };
168
169 pinctrl_serial0: uart0 {
170 groups = "serial_a";
171 function = "serial";
172 };
173 };
174
175 reset@1 {
176 compatible = "sandbox,reset";
177 };
178
179 spi@0 {
180 #address-cells = <1>;
181 #size-cells = <0>;
182 reg = <0 0 0 0>;
183 compatible = "sandbox,spi";
184 cs-gpios = <0>, <&gpio_a 0>;
185 firmware_storage_spi: flash@0 {
186 reg = <0>;
187 compatible = "spansion,m25p16", "sandbox,spi-flash";
188 spi-max-frequency = <40000000>;
189 sandbox,filename = "spi.bin";
190 };
191 };
192
193 spl-test {
194 u-boot,dm-pre-reloc;
195 compatible = "sandbox,spl-test";
196 boolval;
197 intval = <1>;
198 intarray = <2 3 4>;
199 byteval = [05];
200 bytearray = [06];
201 longbytearray = [09 0a 0b 0c 0d 0e 0f 10 11];
202 stringval = "message";
203 stringarray = "multi-word", "message";
204 };
205
206 spl-test2 {
207 u-boot,dm-pre-reloc;
208 compatible = "sandbox,spl-test";
209 intval = <3>;
210 intarray = <5>;
211 byteval = [08];
212 bytearray = [01 23 34];
213 longbytearray = [09 0a 0b 0c];
214 stringval = "message2";
215 stringarray = "another", "multi-word", "message";
216 };
217
218 spl-test3 {
219 u-boot,dm-pre-reloc;
220 compatible = "sandbox,spl-test";
221 stringarray = "one";
222 };
223
224 spl-test4 {
225 u-boot,dm-pre-reloc;
226 compatible = "sandbox,spl-test.2";
227 };
228
229 square {
230 compatible = "demo-shape";
231 colour = "blue";
232 sides = <4>;
233 };
234
235 timer {
236 compatible = "sandbox,timer";
237 clock-frequency = <1000000>;
238 };
239
240 tpm {
241 compatible = "google,sandbox-tpm";
242 };
243
Miquel Raynal80938c12018-05-15 11:57:27 +0200244 tpm2 {
245 compatible = "sandbox,tpm2";
246 };
247
Mario Six61efece2018-02-12 08:05:57 +0100248 triangle {
249 compatible = "demo-shape";
250 colour = "cyan";
251 sides = <3>;
252 character = <83>;
253 light-gpios = <&gpio_a 2>, <&gpio_b 6 0>;
254 };
255
256 /* Needs to be available prior to relocation */
257 uart0: serial {
258 compatible = "sandbox,serial";
259 sandbox,text-colour = "cyan";
260 pinctrl-names = "default";
261 pinctrl-0 = <&pinctrl_serial0>;
262 };
263
264 usb@0 {
265 compatible = "sandbox,usb";
266 status = "disabled";
267 hub {
268 compatible = "sandbox,usb-hub";
269 #address-cells = <1>;
270 #size-cells = <0>;
271 flash-stick {
272 reg = <0>;
273 compatible = "sandbox,usb-flash";
274 };
275 };
276 };
277
278 usb@1 {
279 compatible = "sandbox,usb";
280 hub {
281 compatible = "usb-hub";
282 usb,device-class = <USB_CLASS_HUB>;
283 hub-emul {
284 compatible = "sandbox,usb-hub";
285 #address-cells = <1>;
286 #size-cells = <0>;
287 flash-stick {
288 reg = <0>;
289 compatible = "sandbox,usb-flash";
290 sandbox,filepath = "flash.bin";
291 };
292 };
293 };
294 };
295
296 usb@2 {
297 compatible = "sandbox,usb";
298 status = "disabled";
299 };
300
301 spmi: spmi@0 {
302 compatible = "sandbox,spmi";
303 #address-cells = <0x1>;
304 #size-cells = <0x1>;
305 pm8916@0 {
306 compatible = "qcom,spmi-pmic";
307 reg = <0x0 0x1>;
308 #address-cells = <0x1>;
309 #size-cells = <0x1>;
310
311 spmi_gpios: gpios@c000 {
312 compatible = "qcom,pm8916-gpio";
313 reg = <0xc000 0x400>;
314 gpio-controller;
315 gpio-count = <4>;
316 #gpio-cells = <2>;
317 gpio-bank-name="spmi";
318 };
319 };
320 };
Jens Wiklander86afaa62018-09-25 16:40:16 +0200321
322 sandbox_tee {
323 compatible = "sandbox,tee";
324 };
Mario Six61efece2018-02-12 08:05:57 +0100325};
326
327#include "cros-ec-keyboard.dtsi"
328#include "sandbox_pmic.dtsi"