EASY80920.dtsi 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313
  1. #include "vr9.dtsi"
  2. #include <dt-bindings/input/input.h>
  3. #include <dt-bindings/mips/lantiq_rcu_gphy.h>
  4. / {
  5. compatible = "lantiq,easy80920", "lantiq,xway", "lantiq,vr9";
  6. chosen {
  7. bootargs = "console=ttyLTQ0,115200";
  8. };
  9. aliases {
  10. led-boot = &power;
  11. led-failsafe = &power;
  12. led-running = &power;
  13. led-upgrade = &power;
  14. led-usb = &led_usb1;
  15. led-usb2 = &led_usb2;
  16. };
  17. memory@0 {
  18. reg = <0x0 0x4000000>;
  19. };
  20. gpio-keys-polled {
  21. compatible = "gpio-keys-polled";
  22. #address-cells = <1>;
  23. #size-cells = <0>;
  24. poll-interval = <100>;
  25. /* reset {
  26. label = "reset";
  27. gpios = <&gpio 7 GPIO_ACTIVE_LOW>;
  28. linux,code = <KEY_RESTART>;
  29. };*/
  30. paging {
  31. label = "paging";
  32. gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
  33. linux,code = <KEY_PHONE>;
  34. };
  35. };
  36. gpio-leds {
  37. compatible = "gpio-leds";
  38. power: power {
  39. label = "easy80920:green:power";
  40. gpios = <&stp 9 GPIO_ACTIVE_HIGH>;
  41. default-state = "keep";
  42. };
  43. warning {
  44. label = "easy80920:green:warning";
  45. gpios = <&stp 22 GPIO_ACTIVE_HIGH>;
  46. };
  47. fxs1 {
  48. label = "easy80920:green:fxs1";
  49. gpios = <&stp 21 GPIO_ACTIVE_HIGH>;
  50. };
  51. fxs2 {
  52. label = "easy80920:green:fxs2";
  53. gpios = <&stp 20 GPIO_ACTIVE_HIGH>;
  54. };
  55. fxo {
  56. label = "easy80920:green:fxo";
  57. gpios = <&stp 19 GPIO_ACTIVE_HIGH>;
  58. };
  59. led_usb1: usb1 {
  60. label = "easy80920:green:usb1";
  61. gpios = <&stp 18 GPIO_ACTIVE_HIGH>;
  62. };
  63. led_usb2: usb2 {
  64. label = "easy80920:green:usb2";
  65. gpios = <&stp 15 GPIO_ACTIVE_HIGH>;
  66. };
  67. sd {
  68. label = "easy80920:green:sd";
  69. gpios = <&stp 14 GPIO_ACTIVE_HIGH>;
  70. };
  71. wps {
  72. label = "easy80920:green:wps";
  73. gpios = <&stp 12 GPIO_ACTIVE_HIGH>;
  74. };
  75. };
  76. usb_vbus: regulator-usb-vbus {
  77. compatible = "regulator-fixed";
  78. regulator-name = "USB_VBUS";
  79. regulator-min-microvolt = <5000000>;
  80. regulator-max-microvolt = <5000000>;
  81. gpio = <&gpio 33 GPIO_ACTIVE_HIGH>;
  82. enable-active-high;
  83. };
  84. };
  85. &eth0 {
  86. lan: interface@0 {
  87. compatible = "lantiq,xrx200-pdi";
  88. #address-cells = <1>;
  89. #size-cells = <0>;
  90. reg = <0>;
  91. lantiq,switch;
  92. ethernet@4 {
  93. compatible = "lantiq,xrx200-pdi-port";
  94. reg = <4>;
  95. phy-mode = "gmii";
  96. phy-handle = <&phy13>;
  97. };
  98. ethernet@2 {
  99. compatible = "lantiq,xrx200-pdi-port";
  100. reg = <2>;
  101. phy-mode = "gmii";
  102. phy-handle = <&phy11>;
  103. };
  104. ethernet@1 {
  105. compatible = "lantiq,xrx200-pdi-port";
  106. reg = <1>;
  107. phy-mode = "rgmii";
  108. phy-handle = <&phy1>;
  109. };
  110. ethernet@0 {
  111. compatible = "lantiq,xrx200-pdi-port";
  112. reg = <0>;
  113. phy-mode = "rgmii";
  114. phy-handle = <&phy0>;
  115. };
  116. };
  117. wan: interface@1 {
  118. compatible = "lantiq,xrx200-pdi";
  119. #address-cells = <1>;
  120. #size-cells = <0>;
  121. reg = <1>;
  122. lantiq,wan;
  123. ethernet@5 {
  124. compatible = "lantiq,xrx200-pdi-port";
  125. reg = <5>;
  126. phy-mode = "rgmii";
  127. phy-handle = <&phy5>;
  128. };
  129. };
  130. mdio@0 {
  131. #address-cells = <1>;
  132. #size-cells = <0>;
  133. compatible = "lantiq,xrx200-mdio";
  134. reg = <0>;
  135. phy0: ethernet-phy@0 {
  136. reg = <0x0>;
  137. compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
  138. };
  139. phy1: ethernet-phy@1 {
  140. reg = <0x1>;
  141. compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
  142. };
  143. phy5: ethernet-phy@5 {
  144. reg = <0x5>;
  145. compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
  146. };
  147. phy11: ethernet-phy@11 {
  148. reg = <0x11>;
  149. compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
  150. };
  151. phy13: ethernet-phy@13 {
  152. reg = <0x13>;
  153. compatible = "lantiq,phy11g", "ethernet-phy-ieee802.3-c22";
  154. };
  155. };
  156. };
  157. &gphy0 {
  158. lantiq,gphy-mode = <GPHY_MODE_GE>;
  159. };
  160. &gphy1 {
  161. lantiq,gphy-mode = <GPHY_MODE_GE>;
  162. };
  163. &gpio {
  164. pinctrl-names = "default";
  165. pinctrl-0 = <&state_default>;
  166. state_default: pinmux {
  167. exin3 {
  168. lantiq,groups = "exin3";
  169. lantiq,function = "exin";
  170. };
  171. stp {
  172. lantiq,groups = "stp";
  173. lantiq,function = "stp";
  174. };
  175. nand {
  176. lantiq,groups = "nand cle", "nand ale",
  177. "nand rd", "nand rdy";
  178. lantiq,function = "ebu";
  179. };
  180. mdio {
  181. lantiq,groups = "mdio";
  182. lantiq,function = "mdio";
  183. };
  184. pci {
  185. lantiq,groups = "gnt1", "req1";
  186. lantiq,function = "pci";
  187. };
  188. conf_out {
  189. lantiq,pins = "io24", "io13", "io49", /* nand cle, ale and rd */
  190. "io4", "io5", "io6", /* stp */
  191. "io21",
  192. "io33";
  193. lantiq,open-drain;
  194. lantiq,pull = <0>;
  195. lantiq,output = <1>;
  196. };
  197. pcie-rst {
  198. lantiq,pins = "io38";
  199. lantiq,pull = <0>;
  200. lantiq,output = <1>;
  201. };
  202. conf_in {
  203. lantiq,pins = "io39", /* exin3 */
  204. "io48"; /* nand rdy */
  205. lantiq,pull = <2>;
  206. };
  207. };
  208. pins_spi_default: pins_spi_default {
  209. spi_in {
  210. lantiq,groups = "spi_di";
  211. lantiq,function = "spi";
  212. };
  213. spi_out {
  214. lantiq,groups = "spi_do", "spi_clk",
  215. "spi_cs4";
  216. lantiq,function = "spi";
  217. lantiq,output = <1>;
  218. };
  219. };
  220. };
  221. &spi {
  222. pinctrl-names = "default";
  223. pinctrl-0 = <&pins_spi_default>;
  224. status = "okay";
  225. m25p80@4 {
  226. #address-cells = <1>;
  227. #size-cells = <1>;
  228. compatible = "jedec,spi-nor";
  229. reg = <4 0>;
  230. spi-max-frequency = <1000000>;
  231. partitions {
  232. compatible = "fixed-partitions";
  233. #address-cells = <1>;
  234. #size-cells = <1>;
  235. partition@0 {
  236. reg = <0x0 0x20000>;
  237. label = "SPI (RO) U-Boot Image";
  238. read-only;
  239. };
  240. partition@20000 {
  241. reg = <0x20000 0x10000>;
  242. label = "ENV_MAC";
  243. read-only;
  244. };
  245. partition@30000 {
  246. reg = <0x30000 0x10000>;
  247. label = "DPF";
  248. read-only;
  249. };
  250. partition@40000 {
  251. reg = <0x40000 0x10000>;
  252. label = "NVRAM";
  253. read-only;
  254. };
  255. partition@500000 {
  256. reg = <0x50000 0x003a0000>;
  257. label = "kernel";
  258. };
  259. };
  260. };
  261. };
  262. &stp {
  263. status = "okay";
  264. lantiq,shadow = <0xffff>;
  265. lantiq,groups = <0x7>;
  266. lantiq,dsl = <0x3>;
  267. lantiq,phy1 = <0x7>;
  268. lantiq,phy2 = <0x7>;
  269. /* lantiq,rising; */
  270. };
  271. &usb_phy0 {
  272. status = "okay";
  273. };
  274. &usb0 {
  275. status = "okay";
  276. vbus-supply = <&usb_vbus>;
  277. };