0003-SMILE-Plug-device-tree-file.patch 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210
  1. From ad5cb059a2d3bedda113717012c52afd2d3b10a9 Mon Sep 17 00:00:00 2001
  2. From: Kevin Mihelich <kevin@archlinuxarm.org>
  3. Date: Fri, 5 Sep 2014 15:41:19 -0600
  4. Subject: [PATCH 3/9] SMILE Plug device tree file
  5. This adds a dts file for the SMILE Plug, which only differs from the Mirabox
  6. dts with the LED definitions.
  7. Signed-off-by: Kevin Mihelich <kevin@archlinuxarm.org>
  8. ---
  9. arch/arm/boot/dts/Makefile | 1 +
  10. arch/arm/boot/dts/armada-370-smileplug.dts | 173 +++++++++++++++++++++
  11. 2 files changed, 174 insertions(+)
  12. create mode 100644 arch/arm/boot/dts/armada-370-smileplug.dts
  13. diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
  14. index 08011dc8c7a6..9f10323ecfde 100644
  15. --- a/arch/arm/boot/dts/Makefile
  16. +++ b/arch/arm/boot/dts/Makefile
  17. @@ -1227,6 +1227,7 @@ dtb-$(CONFIG_MACH_ARMADA_370) += \
  18. armada-370-db.dtb \
  19. armada-370-dlink-dns327l.dtb \
  20. armada-370-mirabox.dtb \
  21. + armada-370-smileplug.dtb \
  22. armada-370-netgear-rn102.dtb \
  23. armada-370-netgear-rn104.dtb \
  24. armada-370-rd.dtb \
  25. diff --git a/arch/arm/boot/dts/armada-370-smileplug.dts b/arch/arm/boot/dts/armada-370-smileplug.dts
  26. new file mode 100644
  27. index 000000000000..d01308ab848b
  28. --- /dev/null
  29. +++ b/arch/arm/boot/dts/armada-370-smileplug.dts
  30. @@ -0,0 +1,173 @@
  31. +/*
  32. + * Device Tree file for Marvell SMILE Plug
  33. + *
  34. + * Kevin Mihelich <kevin@archlinuxarm.org>
  35. + * Gregory CLEMENT <gregory.clement@free-electrons.com>
  36. + *
  37. + * This file is licensed under the terms of the GNU General Public
  38. + * License version 2. This program is licensed "as is" without any
  39. + * warranty of any kind, whether express or implied.
  40. + */
  41. +
  42. +/dts-v1/;
  43. +#include <dt-bindings/gpio/gpio.h>
  44. +#include "armada-370.dtsi"
  45. +
  46. +/ {
  47. + model = "Marvell SMILE Plug";
  48. + compatible = "marvell,smileplug", "marvell,armada370", "marvell,armada-370-xp";
  49. +
  50. + chosen {
  51. + bootargs = "console=ttyS0,115200 earlyprintk";
  52. + };
  53. +
  54. + memory {
  55. + device_type = "memory";
  56. + reg = <0x00000000 0x20000000>; /* 512 MB */
  57. + };
  58. +
  59. + soc {
  60. + ranges = <MBUS_ID(0xf0, 0x01) 0 0xd0000000 0x100000
  61. + MBUS_ID(0x01, 0xe0) 0 0xfff00000 0x100000>;
  62. +
  63. + pcie-controller {
  64. + status = "okay";
  65. +
  66. + /* Internal mini-PCIe connector */
  67. + pcie@1,0 {
  68. + /* Port 0, Lane 0 */
  69. + status = "okay";
  70. + };
  71. +
  72. + /* Connected on the PCB to a USB 3.0 XHCI controller */
  73. + pcie@2,0 {
  74. + /* Port 1, Lane 0 */
  75. + status = "okay";
  76. + };
  77. + };
  78. +
  79. + internal-regs {
  80. + serial@12000 {
  81. + status = "okay";
  82. + };
  83. + timer@20300 {
  84. + clock-frequency = <600000000>;
  85. + status = "okay";
  86. + };
  87. +
  88. + gpio_leds {
  89. + compatible = "gpio-leds";
  90. + pinctrl-names = "default";
  91. + pinctrl-0 = <&smile_led_pins>;
  92. +
  93. + red_eyes_led {
  94. + label = "smileplug:red:eyes";
  95. + gpios = <&gpio1 31 0>;
  96. + default-state = "off";
  97. + };
  98. +
  99. + green_eyes_led {
  100. + label = "smileplug:green:eyes";
  101. + gpios = <&gpio2 0 0>;
  102. + linux,default-trigger = "default-on";
  103. + };
  104. +
  105. + red_smile_led {
  106. + label = "smileplug:red:smile";
  107. + gpios = <&gpio1 15 0>;
  108. + default-state = "off";
  109. + };
  110. +
  111. + green_smile_led {
  112. + label = "smileplug:green:smile";
  113. + gpios = <&gpio1 27 0>;
  114. + linux,default-trigger = "default-on";
  115. + };
  116. + };
  117. +
  118. + mdio {
  119. + pinctrl-0 = <&mdio_pins>;
  120. + pinctrl-names = "default";
  121. + phy0: ethernet-phy@0 {
  122. + reg = <0>;
  123. + };
  124. +
  125. + phy1: ethernet-phy@1 {
  126. + reg = <1>;
  127. + };
  128. + };
  129. + ethernet@70000 {
  130. + pinctrl-0 = <&ge0_rgmii_pins>;
  131. + pinctrl-names = "default";
  132. + status = "okay";
  133. + phy = <&phy0>;
  134. + phy-mode = "rgmii-id";
  135. + };
  136. + ethernet@74000 {
  137. + pinctrl-0 = <&ge1_rgmii_pins>;
  138. + pinctrl-names = "default";
  139. + status = "okay";
  140. + phy = <&phy1>;
  141. + phy-mode = "rgmii-id";
  142. + };
  143. +
  144. + mvsdio@d4000 {
  145. + pinctrl-0 = <&sdio_pins3>;
  146. + pinctrl-names = "default";
  147. + status = "okay";
  148. + /*
  149. + * No CD or WP GPIOs: SDIO interface used for
  150. + * Wifi/Bluetooth chip
  151. + */
  152. + broken-cd;
  153. + };
  154. +
  155. + usb@50000 {
  156. + status = "okay";
  157. + };
  158. +
  159. + usb@51000 {
  160. + status = "okay";
  161. + };
  162. +
  163. + i2c@11000 {
  164. + status = "okay";
  165. + clock-frequency = <100000>;
  166. + pca9505: pca9505@25 {
  167. + compatible = "nxp,pca9505";
  168. + gpio-controller;
  169. + #gpio-cells = <2>;
  170. + reg = <0x25>;
  171. + };
  172. + };
  173. +
  174. + nand@d0000 {
  175. + status = "okay";
  176. + num-cs = <1>;
  177. + marvell,nand-keep-config;
  178. + marvell,nand-enable-arbiter;
  179. + nand-on-flash-bbt;
  180. +
  181. + partition@0 {
  182. + label = "U-Boot";
  183. + reg = <0 0x400000>;
  184. + };
  185. + partition@400000 {
  186. + label = "Linux";
  187. + reg = <0x400000 0x400000>;
  188. + };
  189. + partition@800000 {
  190. + label = "Filesystem";
  191. + reg = <0x800000 0x3f800000>;
  192. + };
  193. + };
  194. + };
  195. + };
  196. +};
  197. +
  198. +&pinctrl {
  199. + smile_led_pins: smile-led-pins {
  200. + marvell,pins = "mpp63", "mpp64", "mpp47", "mpp59";
  201. + marvell,function = "gpio";
  202. + };
  203. +};
  204. --
  205. 2.23.0