Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 1 | /dts-v1/; |
| 2 | |
| 3 | / { |
| 4 | model = "sandbox"; |
| 5 | compatible = "sandbox"; |
| 6 | #address-cells = <1>; |
Simon Glass | 0503e82 | 2015-07-06 12:54:36 -0600 | [diff] [blame] | 7 | #size-cells = <1>; |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 8 | |
Simon Glass | 00606d7 | 2014-07-23 06:55:03 -0600 | [diff] [blame] | 9 | aliases { |
| 10 | console = &uart0; |
Simon Glass | 171e991 | 2015-05-22 15:42:15 -0600 | [diff] [blame] | 11 | eth0 = "/eth@10002000"; |
| 12 | eth5 = ð_5; |
Simon Glass | 9cc36a2 | 2015-01-25 08:27:05 -0700 | [diff] [blame] | 13 | i2c0 = "/i2c@0"; |
Przemyslaw Marczak | f64000c | 2015-05-13 13:38:34 +0200 | [diff] [blame] | 14 | pci0 = &pci; |
Simon Glass | 52d3bc5 | 2015-05-22 15:42:17 -0600 | [diff] [blame] | 15 | rtc0 = &rtc_0; |
| 16 | rtc1 = &rtc_1; |
Simon Glass | 171e991 | 2015-05-22 15:42:15 -0600 | [diff] [blame] | 17 | spi0 = "/spi@0"; |
Przemyslaw Marczak | f64000c | 2015-05-13 13:38:34 +0200 | [diff] [blame] | 18 | testfdt6 = "/e-test"; |
Simon Glass | 9cc36a2 | 2015-01-25 08:27:05 -0700 | [diff] [blame] | 19 | testbus3 = "/some-bus"; |
| 20 | testfdt0 = "/some-bus/c-test@0"; |
| 21 | testfdt1 = "/some-bus/c-test@1"; |
| 22 | testfdt3 = "/b-test"; |
| 23 | testfdt5 = "/some-bus/c-test@5"; |
| 24 | testfdt8 = "/a-test"; |
Simon Glass | e00cb22 | 2015-03-25 12:23:05 -0600 | [diff] [blame] | 25 | usb0 = &usb_0; |
| 26 | usb1 = &usb_1; |
| 27 | usb2 = &usb_2; |
Simon Glass | 00606d7 | 2014-07-23 06:55:03 -0600 | [diff] [blame] | 28 | }; |
| 29 | |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 30 | a-test { |
Simon Glass | 0503e82 | 2015-07-06 12:54:36 -0600 | [diff] [blame] | 31 | reg = <0 1>; |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 32 | compatible = "denx,u-boot-fdt-test"; |
Simon Glass | eb9ef5f | 2014-07-23 06:54:57 -0600 | [diff] [blame] | 33 | ping-expect = <0>; |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 34 | ping-add = <0>; |
Simon Glass | 00606d7 | 2014-07-23 06:55:03 -0600 | [diff] [blame] | 35 | u-boot,dm-pre-reloc; |
Simon Glass | 3669e0e | 2015-01-05 20:05:29 -0700 | [diff] [blame] | 36 | test-gpios = <&gpio_a 1>, <&gpio_a 4>, <&gpio_b 5 0 3 2 1>, |
| 37 | <0>, <&gpio_a 12>; |
| 38 | test2-gpios = <&gpio_a 1>, <&gpio_a 4>, <&gpio_b 6 1 3 2 1>, |
| 39 | <&gpio_b 7 2 3 2 1>, <&gpio_b 8 4 3 2 1>, |
| 40 | <&gpio_b 9 0xc 3 2 1>; |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 41 | }; |
| 42 | |
| 43 | junk { |
Simon Glass | 0503e82 | 2015-07-06 12:54:36 -0600 | [diff] [blame] | 44 | reg = <1 1>; |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 45 | compatible = "not,compatible"; |
| 46 | }; |
| 47 | |
| 48 | no-compatible { |
Simon Glass | 0503e82 | 2015-07-06 12:54:36 -0600 | [diff] [blame] | 49 | reg = <2 1>; |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 50 | }; |
| 51 | |
| 52 | b-test { |
Simon Glass | 0503e82 | 2015-07-06 12:54:36 -0600 | [diff] [blame] | 53 | reg = <3 1>; |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 54 | compatible = "denx,u-boot-fdt-test"; |
Simon Glass | eb9ef5f | 2014-07-23 06:54:57 -0600 | [diff] [blame] | 55 | ping-expect = <3>; |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 56 | ping-add = <3>; |
| 57 | }; |
| 58 | |
| 59 | some-bus { |
| 60 | #address-cells = <1>; |
| 61 | #size-cells = <0>; |
Simon Glass | 1ca7e20 | 2014-07-23 06:55:18 -0600 | [diff] [blame] | 62 | compatible = "denx,u-boot-test-bus"; |
Simon Glass | 0503e82 | 2015-07-06 12:54:36 -0600 | [diff] [blame] | 63 | reg = <3 1>; |
Simon Glass | eb9ef5f | 2014-07-23 06:54:57 -0600 | [diff] [blame] | 64 | ping-expect = <4>; |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 65 | ping-add = <4>; |
Simon Glass | 1ca7e20 | 2014-07-23 06:55:18 -0600 | [diff] [blame] | 66 | c-test@5 { |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 67 | compatible = "denx,u-boot-fdt-test"; |
| 68 | reg = <5>; |
Simon Glass | 1ca7e20 | 2014-07-23 06:55:18 -0600 | [diff] [blame] | 69 | ping-expect = <5>; |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 70 | ping-add = <5>; |
| 71 | }; |
Simon Glass | 1ca7e20 | 2014-07-23 06:55:18 -0600 | [diff] [blame] | 72 | c-test@0 { |
| 73 | compatible = "denx,u-boot-fdt-test"; |
| 74 | reg = <0>; |
| 75 | ping-expect = <6>; |
| 76 | ping-add = <6>; |
| 77 | }; |
| 78 | c-test@1 { |
| 79 | compatible = "denx,u-boot-fdt-test"; |
| 80 | reg = <1>; |
| 81 | ping-expect = <7>; |
| 82 | ping-add = <7>; |
| 83 | }; |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 84 | }; |
| 85 | |
| 86 | d-test { |
Simon Glass | 0503e82 | 2015-07-06 12:54:36 -0600 | [diff] [blame] | 87 | reg = <3 1>; |
Simon Glass | 5a66a8f | 2014-07-23 06:55:12 -0600 | [diff] [blame] | 88 | ping-expect = <6>; |
| 89 | ping-add = <6>; |
| 90 | compatible = "google,another-fdt-test"; |
| 91 | }; |
| 92 | |
| 93 | e-test { |
Simon Glass | 0503e82 | 2015-07-06 12:54:36 -0600 | [diff] [blame] | 94 | reg = <3 1>; |
Simon Glass | eb9ef5f | 2014-07-23 06:54:57 -0600 | [diff] [blame] | 95 | ping-expect = <6>; |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 96 | ping-add = <6>; |
| 97 | compatible = "google,another-fdt-test"; |
| 98 | }; |
| 99 | |
Simon Glass | 9cc36a2 | 2015-01-25 08:27:05 -0700 | [diff] [blame] | 100 | f-test { |
| 101 | compatible = "denx,u-boot-fdt-test"; |
| 102 | }; |
| 103 | |
| 104 | g-test { |
| 105 | compatible = "denx,u-boot-fdt-test"; |
| 106 | }; |
| 107 | |
Simon Glass | 6a1c7ce | 2015-07-06 12:54:24 -0600 | [diff] [blame] | 108 | clk@0 { |
| 109 | compatible = "sandbox,clk"; |
| 110 | }; |
| 111 | |
Simon Glass | 171e991 | 2015-05-22 15:42:15 -0600 | [diff] [blame] | 112 | eth@10002000 { |
| 113 | compatible = "sandbox,eth"; |
| 114 | reg = <0x10002000 0x1000>; |
| 115 | fake-host-hwaddr = <0x00 0x00 0x66 0x44 0x22 0x00>; |
| 116 | }; |
| 117 | |
| 118 | eth_5: eth@10003000 { |
| 119 | compatible = "sandbox,eth"; |
| 120 | reg = <0x10003000 0x1000>; |
| 121 | fake-host-hwaddr = <0x00 0x00 0x66 0x44 0x22 0x11>; |
| 122 | }; |
| 123 | |
| 124 | eth@10004000 { |
| 125 | compatible = "sandbox,eth"; |
| 126 | reg = <0x10004000 0x1000>; |
| 127 | fake-host-hwaddr = <0x00 0x00 0x66 0x44 0x22 0x22>; |
| 128 | }; |
| 129 | |
Simon Glass | 0ae0cb7 | 2014-10-13 23:42:11 -0600 | [diff] [blame] | 130 | gpio_a: base-gpios { |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 131 | compatible = "sandbox,gpio"; |
Simon Glass | 3669e0e | 2015-01-05 20:05:29 -0700 | [diff] [blame] | 132 | gpio-controller; |
| 133 | #gpio-cells = <1>; |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 134 | gpio-bank-name = "a"; |
| 135 | num-gpios = <20>; |
| 136 | }; |
| 137 | |
Simon Glass | 3669e0e | 2015-01-05 20:05:29 -0700 | [diff] [blame] | 138 | gpio_b: extra-gpios { |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 139 | compatible = "sandbox,gpio"; |
Simon Glass | 3669e0e | 2015-01-05 20:05:29 -0700 | [diff] [blame] | 140 | gpio-controller; |
| 141 | #gpio-cells = <5>; |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 142 | gpio-bank-name = "b"; |
| 143 | num-gpios = <10>; |
| 144 | }; |
Simon Glass | 0ae0cb7 | 2014-10-13 23:42:11 -0600 | [diff] [blame] | 145 | |
Simon Glass | ecc2ed5 | 2014-12-10 08:55:55 -0700 | [diff] [blame] | 146 | i2c@0 { |
| 147 | #address-cells = <1>; |
| 148 | #size-cells = <0>; |
Simon Glass | 0503e82 | 2015-07-06 12:54:36 -0600 | [diff] [blame] | 149 | reg = <0 1>; |
Simon Glass | ecc2ed5 | 2014-12-10 08:55:55 -0700 | [diff] [blame] | 150 | compatible = "sandbox,i2c"; |
| 151 | clock-frequency = <100000>; |
| 152 | eeprom@2c { |
| 153 | reg = <0x2c>; |
| 154 | compatible = "i2c-eeprom"; |
| 155 | emul { |
| 156 | compatible = "sandbox,i2c-eeprom"; |
| 157 | sandbox,filename = "i2c.bin"; |
| 158 | sandbox,size = <256>; |
| 159 | }; |
| 160 | }; |
Przemyslaw Marczak | 9038cd5 | 2015-05-13 13:38:35 +0200 | [diff] [blame] | 161 | |
Simon Glass | 52d3bc5 | 2015-05-22 15:42:17 -0600 | [diff] [blame] | 162 | rtc_0: rtc@43 { |
| 163 | reg = <0x43>; |
| 164 | compatible = "sandbox-rtc"; |
| 165 | emul { |
| 166 | compatible = "sandbox,i2c-rtc"; |
| 167 | }; |
| 168 | }; |
| 169 | |
| 170 | rtc_1: rtc@61 { |
| 171 | reg = <0x61>; |
| 172 | compatible = "sandbox-rtc"; |
| 173 | emul { |
| 174 | compatible = "sandbox,i2c-rtc"; |
| 175 | }; |
| 176 | }; |
| 177 | |
Przemyslaw Marczak | 9038cd5 | 2015-05-13 13:38:35 +0200 | [diff] [blame] | 178 | sandbox_pmic: sandbox_pmic { |
| 179 | reg = <0x40>; |
| 180 | }; |
Simon Glass | ecc2ed5 | 2014-12-10 08:55:55 -0700 | [diff] [blame] | 181 | }; |
| 182 | |
Simon Glass | 3c43fba | 2015-07-06 12:54:34 -0600 | [diff] [blame] | 183 | leds { |
| 184 | compatible = "gpio-leds"; |
| 185 | |
| 186 | iracibble { |
| 187 | gpios = <&gpio_a 1 0>; |
| 188 | label = "sandbox:red"; |
| 189 | }; |
| 190 | |
| 191 | martinet { |
| 192 | gpios = <&gpio_a 2 0>; |
| 193 | label = "sandbox:green"; |
| 194 | }; |
| 195 | }; |
| 196 | |
Simon Glass | 8e6cc46 | 2015-07-06 12:54:32 -0600 | [diff] [blame] | 197 | mmc { |
| 198 | compatible = "sandbox,mmc"; |
| 199 | }; |
| 200 | |
Simon Glass | d3b7ff1 | 2015-03-05 12:25:34 -0700 | [diff] [blame] | 201 | pci: pci-controller { |
| 202 | compatible = "sandbox,pci"; |
| 203 | device_type = "pci"; |
| 204 | #address-cells = <3>; |
| 205 | #size-cells = <2>; |
| 206 | ranges = <0x02000000 0 0x10000000 0x10000000 0 0x2000 |
| 207 | 0x01000000 0 0x20000000 0x20000000 0 0x2000>; |
| 208 | pci@1f,0 { |
| 209 | compatible = "pci-generic"; |
| 210 | reg = <0xf800 0 0 0 0>; |
| 211 | emul@1f,0 { |
| 212 | compatible = "sandbox,swap-case"; |
| 213 | }; |
| 214 | }; |
| 215 | }; |
| 216 | |
Simon Glass | 64ce0ca | 2015-07-06 12:54:31 -0600 | [diff] [blame] | 217 | ram { |
| 218 | compatible = "sandbox,ram"; |
| 219 | }; |
| 220 | |
Simon Glass | 5010d98 | 2015-07-06 12:54:29 -0600 | [diff] [blame] | 221 | reset@0 { |
| 222 | compatible = "sandbox,warm-reset"; |
| 223 | }; |
| 224 | |
| 225 | reset@1 { |
| 226 | compatible = "sandbox,reset"; |
| 227 | }; |
| 228 | |
Simon Glass | 0ae0cb7 | 2014-10-13 23:42:11 -0600 | [diff] [blame] | 229 | spi@0 { |
| 230 | #address-cells = <1>; |
| 231 | #size-cells = <0>; |
Simon Glass | 0503e82 | 2015-07-06 12:54:36 -0600 | [diff] [blame] | 232 | reg = <0 1>; |
Simon Glass | 0ae0cb7 | 2014-10-13 23:42:11 -0600 | [diff] [blame] | 233 | compatible = "sandbox,spi"; |
| 234 | cs-gpios = <0>, <&gpio_a 0>; |
| 235 | spi.bin@0 { |
| 236 | reg = <0>; |
| 237 | compatible = "spansion,m25p16", "spi-flash"; |
| 238 | spi-max-frequency = <40000000>; |
| 239 | sandbox,filename = "spi.bin"; |
| 240 | }; |
| 241 | }; |
| 242 | |
Simon Glass | 04035fd | 2015-07-06 12:54:35 -0600 | [diff] [blame] | 243 | syscon@0 { |
| 244 | compatible = "sandbox,syscon0"; |
Simon Glass | 0503e82 | 2015-07-06 12:54:36 -0600 | [diff] [blame] | 245 | reg = <0x10 4>; |
Simon Glass | 04035fd | 2015-07-06 12:54:35 -0600 | [diff] [blame] | 246 | }; |
| 247 | |
| 248 | syscon@1 { |
| 249 | compatible = "sandbox,syscon1"; |
Simon Glass | 0503e82 | 2015-07-06 12:54:36 -0600 | [diff] [blame] | 250 | reg = <0x20 5 |
| 251 | 0x28 6 |
| 252 | 0x30 7 |
| 253 | 0x38 8>; |
Simon Glass | 04035fd | 2015-07-06 12:54:35 -0600 | [diff] [blame] | 254 | }; |
| 255 | |
Simon Glass | 171e991 | 2015-05-22 15:42:15 -0600 | [diff] [blame] | 256 | uart0: serial { |
| 257 | compatible = "sandbox,serial"; |
| 258 | u-boot,dm-pre-reloc; |
Joe Hershberger | bfacad7 | 2015-03-22 17:09:15 -0500 | [diff] [blame] | 259 | }; |
| 260 | |
Simon Glass | e00cb22 | 2015-03-25 12:23:05 -0600 | [diff] [blame] | 261 | usb_0: usb@0 { |
| 262 | compatible = "sandbox,usb"; |
| 263 | status = "disabled"; |
| 264 | hub { |
| 265 | compatible = "sandbox,usb-hub"; |
| 266 | #address-cells = <1>; |
| 267 | #size-cells = <0>; |
| 268 | flash-stick { |
| 269 | reg = <0>; |
| 270 | compatible = "sandbox,usb-flash"; |
| 271 | }; |
| 272 | }; |
| 273 | }; |
| 274 | |
| 275 | usb_1: usb@1 { |
| 276 | compatible = "sandbox,usb"; |
| 277 | hub { |
| 278 | compatible = "usb-hub"; |
| 279 | usb,device-class = <9>; |
| 280 | hub-emul { |
| 281 | compatible = "sandbox,usb-hub"; |
| 282 | #address-cells = <1>; |
| 283 | #size-cells = <0>; |
| 284 | flash-stick { |
| 285 | reg = <0>; |
| 286 | compatible = "sandbox,usb-flash"; |
| 287 | sandbox,filepath = "testflash.bin"; |
| 288 | }; |
| 289 | |
| 290 | }; |
| 291 | }; |
| 292 | }; |
| 293 | |
| 294 | usb_2: usb@2 { |
| 295 | compatible = "sandbox,usb"; |
| 296 | status = "disabled"; |
| 297 | }; |
| 298 | |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 299 | }; |
Przemyslaw Marczak | 9038cd5 | 2015-05-13 13:38:35 +0200 | [diff] [blame] | 300 | |
| 301 | #include "sandbox_pmic.dtsi" |