Guest User

sun7i-a20-bananapro.dts

a guest
Feb 11th, 2015
513
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. /dts-v1/;
  2. #include "sun7i-a20.dtsi"
  3. #include "sunxi-common-regulators.dtsi"
  4. #include <dt-bindings/gpio/gpio.h>
  5. #include <dt-bindings/interrupt-controller/arm-gic.h>
  6.  
  7. / {
  8. model = "LeMaker Banana Pro";
  9. compatible = "lemaker,bananapro", "allwinner,sun7i-a20";
  10.  
  11. leds {
  12. compatible = "gpio-leds";
  13. pinctrl-names = "default";
  14. pinctrl-0 = <&led_pins_bananapro>;
  15.  
  16. blue {
  17. label = "bananapro:blue:usr";
  18. gpios = <&pio 6 2 GPIO_ACTIVE_HIGH>;
  19. };
  20.  
  21. green {
  22. label = "bananapro:green:usr";
  23. gpios = <&pio 7 24 GPIO_ACTIVE_HIGH>;
  24. };
  25. };
  26.  
  27. reg_gmac_3v3: gmac-3v3 {
  28. compatible = "regulator-fixed";
  29. pinctrl-names = "default";
  30. pinctrl-0 = <&gmac_power_pin_bananapro>;
  31. regulator-name = "gmac-3v3";
  32. regulator-min-microvolt = <3300000>;
  33. regulator-max-microvolt = <3300000>;
  34. startup-delay-us = <100000>;
  35. enable-active-high;
  36. gpio = <&pio 7 23 GPIO_ACTIVE_HIGH>;
  37. };
  38.  
  39. reg_vmmc3: vmmc3 {
  40. compatible = "regulator-fixed";
  41. pinctrl-names = "default";
  42. pinctrl-0 = <&vmmc3_pin_bananapro>;
  43. regulator-name = "vmmc3";
  44. regulator-min-microvolt = <3300000>;
  45. regulator-max-microvolt = <3300000>;
  46. enable-active-high;
  47. gpio = <&pio 7 22 GPIO_ACTIVE_HIGH>;
  48. };
  49. };
  50.  
  51. &ahci {
  52. status = "okay";
  53. };
  54.  
  55. &ehci0 {
  56. status = "okay";
  57. };
  58.  
  59. &ehci1 {
  60. status = "okay";
  61. };
  62.  
  63. &gmac {
  64. pinctrl-names = "default";
  65. pinctrl-0 = <&gmac_pins_rgmii_a>;
  66. phy = <&phy1>;
  67. phy-mode = "rgmii";
  68. phy-supply = <&reg_gmac_3v3>;
  69. status = "okay";
  70.  
  71. phy1: ethernet-phy@1 {
  72. reg = <1>;
  73. };
  74. };
  75.  
  76. &i2c0 {
  77. pinctrl-names = "default";
  78. pinctrl-0 = <&i2c0_pins_a>;
  79. status = "okay";
  80.  
  81. axp209: pmic@34 {
  82. compatible = "x-powers,axp209";
  83. reg = <0x34>;
  84. interrupt-parent = <&nmi_intc>;
  85. interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
  86.  
  87. interrupt-controller;
  88. #interrupt-cells = <1>;
  89. };
  90. };
  91.  
  92. &i2c2 {
  93. pinctrl-names = "default";
  94. pinctrl-0 = <&i2c2_pins_a>;
  95. status = "okay";
  96. };
  97.  
  98. &ir0 {
  99. pinctrl-names = "default";
  100. pinctrl-0 = <&ir0_pins_a>;
  101. status = "okay";
  102. };
  103.  
  104. &mmc0 {
  105. pinctrl-names = "default";
  106. pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_bananapro>;
  107. vmmc-supply = <&reg_vcc3v3>;
  108. bus-width = <4>;
  109. cd-gpios = <&pio 7 10 GPIO_ACTIVE_HIGH>; /* PH10 */
  110. cd-inverted;
  111. status = "okay";
  112. };
  113.  
  114. &mmc3 {
  115. pinctrl-names = "default";
  116. pinctrl-0 = <&mmc3_pins_a>;
  117. vmmc-supply = <&reg_vmmc3>;
  118. bus-width = <4>;
  119. non-removable;
  120. status = "okay";
  121. };
  122.  
  123. &ohci0 {
  124. status = "okay";
  125. };
  126.  
  127. &ohci1 {
  128. status = "okay";
  129. };
  130.  
  131. &pio {
  132. gmac_power_pin_bananapro: gmac_power_pin@0 {
  133. allwinner,pins = "PH23";
  134. allwinner,function = "gpio_out";
  135. allwinner,drive = <0>;
  136. allwinner,pull = <0>;
  137. };
  138.  
  139. led_pins_bananapro: led_pins@0 {
  140. allwinner,pins = "PH24", "PG2";
  141. allwinner,function = "gpio_out";
  142. allwinner,drive = <0>;
  143. allwinner,pull = <0>;
  144. };
  145.  
  146. mmc0_cd_pin_bananapro: mmc0_cd_pin@0 {
  147. allwinner,pins = "PH10";
  148. allwinner,function = "gpio_in";
  149. allwinner,drive = <0>;
  150. allwinner,pull = <1>;
  151. };
  152.  
  153. usb1_vbus_pin_bananapro: usb1_vbus_pin@0 {
  154. allwinner,pins = "PH0";
  155. allwinner,function = "gpio_out";
  156. allwinner,drive = <0>;
  157. allwinner,pull = <0>;
  158. };
  159.  
  160. usb2_vbus_pin_bananapro: usb2_vbus_pin@0 {
  161. allwinner,pins = "PH1";
  162. allwinner,function = "gpio_out";
  163. allwinner,drive = <0>;
  164. allwinner,pull = <0>;
  165. };
  166.  
  167. vmmc3_pin_bananapro: vmmc3_pin@0 {
  168. allwinner,pins = "PH22";
  169. allwinner,function = "gpio_out";
  170. allwinner,drive = <0>;
  171. allwinner,pull = <0>;
  172. };
  173. };
  174.  
  175. &reg_usb1_vbus {
  176. pinctrl-0 = <&usb1_vbus_pin_bananapro>;
  177. gpio = <&pio 7 0 GPIO_ACTIVE_HIGH>; /* PH0 */
  178. status = "okay";
  179. };
  180.  
  181. &reg_usb2_vbus {
  182. pinctrl-0 = <&usb2_vbus_pin_bananapro>;
  183. gpio = <&pio 7 1 GPIO_ACTIVE_HIGH>; /* PH1 */
  184. status = "okay";
  185. };
  186.  
  187. &spi0 {
  188. pinctrl-names = "default";
  189. pinctrl-0 = <&spi0_pins_a>;
  190. status = "okay";
  191. };
  192.  
  193. &uart0 {
  194. pinctrl-names = "default";
  195. pinctrl-0 = <&uart0_pins_a>;
  196. status = "okay";
  197. };
  198.  
  199. &uart2 {
  200. pinctrl-names = "default";
  201. pinctrl-0 = <&uart2_pins_a>;
  202. status = "okay";
  203. };
  204.  
  205. &uart7 {
  206. pinctrl-names = "default";
  207. pinctrl-0 = <&uart7_pins_a>;
  208. status = "okay";
  209. };
  210.  
  211. &usbphy {
  212. usb1_vbus-supply = <&reg_usb1_vbus>;
  213. usb2_vbus-supply = <&reg_usb2_vbus>;
  214. status = "okay";
  215. };
RAW Paste Data