test.dts 5.2 KB

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