r7s9210-rza2mevb.dts 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249
  1. // SPDX-License-Identifier: GPL-2.0
  2. /*
  3. * Device Tree Source for the RZA2MEVB board
  4. *
  5. * Copyright (C) 2018 Renesas Electronics
  6. *
  7. * As upstream Linux does not support XIP, it cannot run in 8 MiB of HyperRAM.
  8. * Hence the 64 MiB of SDRAM on the sub-board needs to be enabled, which has
  9. * the following ramifications:
  10. * - SCIF4 connected to the on-board USB-serial can no longer be used as the
  11. * serial console,
  12. * - Instead, SCIF2 is used as the serial console, by connecting a 3.3V TTL
  13. * USB-to-Serial adapter to the CMOS camera connector:
  14. * - RXD = CN17-9,
  15. * - TXD = CN17-10,
  16. * - GND = CN17-2 or CN17-17,
  17. * - The first Ethernet channel can no longer be used,
  18. * - USB Channel 1 loses the overcurrent input signal.
  19. *
  20. * Please make sure your sub-board matches the following switch settings:
  21. *
  22. * SW6 SW6-1 set to SDRAM
  23. * ON SW6-2 set to Audio
  24. * +---------------------+ SW6-3 set to DRP
  25. * | = = = = = | SW6-4 set to CEU
  26. * | = = | SW6-5 set to Ether2
  27. * | 1 2 3 4 5 6 7 8 9 0 | SW6-6 set to VDC6
  28. * +---------------------+ SW6-7 set to VDC6
  29. */
  30. /dts-v1/;
  31. #include "r7s9210.dtsi"
  32. #include <dt-bindings/gpio/gpio.h>
  33. #include <dt-bindings/input/input.h>
  34. #include <dt-bindings/pinctrl/r7s9210-pinctrl.h>
  35. / {
  36. model = "RZA2MEVB";
  37. compatible = "renesas,rza2mevb", "renesas,r7s9210";
  38. aliases {
  39. serial0 = &scif2;
  40. ethernet0 = &ether1;
  41. };
  42. chosen {
  43. bootargs = "ignore_loglevel";
  44. stdout-path = "serial0:115200n8";
  45. };
  46. keyboard {
  47. compatible = "gpio-keys";
  48. pinctrl-names = "default";
  49. pinctrl-0 = <&keyboard_pins>;
  50. key-3 {
  51. interrupt-parent = <&irqc>;
  52. interrupts = <0 IRQ_TYPE_EDGE_BOTH>;
  53. linux,code = <KEY_3>;
  54. label = "SW3";
  55. wakeup-source;
  56. };
  57. };
  58. lbsc {
  59. #address-cells = <1>;
  60. #size-cells = <1>;
  61. };
  62. leds {
  63. compatible = "gpio-leds";
  64. led-red {
  65. gpios = <&pinctrl RZA2_PIN(PORT6, 0) GPIO_ACTIVE_HIGH>;
  66. };
  67. led-green {
  68. gpios = <&pinctrl RZA2_PIN(PORTC, 1) GPIO_ACTIVE_HIGH>;
  69. };
  70. };
  71. memory@c000000 {
  72. device_type = "memory";
  73. reg = <0x0c000000 0x04000000>; /* SDRAM */
  74. };
  75. };
  76. &ehci0 {
  77. status = "okay";
  78. };
  79. &ehci1 {
  80. status = "okay";
  81. };
  82. &ether1 {
  83. pinctrl-names = "default";
  84. pinctrl-0 = <&eth1_pins>;
  85. status = "okay";
  86. renesas,no-ether-link;
  87. phy-handle = <&phy1>;
  88. phy1: ethernet-phy@1 {
  89. compatible = "ethernet-phy-id001c.c816",
  90. "ethernet-phy-ieee802.3-c22";
  91. reg = <0>;
  92. };
  93. };
  94. /* EXTAL */
  95. &extal_clk {
  96. clock-frequency = <24000000>; /* 24MHz */
  97. };
  98. &i2c3 {
  99. status = "okay";
  100. clock-frequency = <400000>;
  101. pinctrl-names = "default";
  102. pinctrl-0 = <&i2c3_pins>;
  103. eeprom@50 {
  104. compatible = "renesas,r1ex24128", "atmel,24c128";
  105. reg = <0x50>;
  106. pagesize = <64>;
  107. };
  108. };
  109. /* High resolution System tick timers */
  110. &ostm0 {
  111. status = "okay";
  112. };
  113. &ostm1 {
  114. status = "okay";
  115. };
  116. &pinctrl {
  117. eth0_pins: eth0 {
  118. pinmux = <RZA2_PINMUX(PORTE, 0, 7)>, /* REF50CK0 */
  119. <RZA2_PINMUX(PORT6, 1, 7)>, /* RMMI0_TXDEN */
  120. <RZA2_PINMUX(PORT6, 2, 7)>, /* RMII0_TXD0 */
  121. <RZA2_PINMUX(PORT6, 3, 7)>, /* RMII0_TXD1 */
  122. <RZA2_PINMUX(PORTE, 4, 7)>, /* RMII0_CRSDV */
  123. <RZA2_PINMUX(PORTE, 1, 7)>, /* RMII0_RXD0 */
  124. <RZA2_PINMUX(PORTE, 2, 7)>, /* RMII0_RXD1 */
  125. <RZA2_PINMUX(PORTE, 3, 7)>, /* RMII0_RXER */
  126. <RZA2_PINMUX(PORTE, 5, 1)>, /* ET0_MDC */
  127. <RZA2_PINMUX(PORTE, 6, 1)>, /* ET0_MDIO */
  128. <RZA2_PINMUX(PORTL, 0, 5)>; /* IRQ4 */
  129. };
  130. eth1_pins: eth1 {
  131. pinmux = <RZA2_PINMUX(PORTK, 3, 7)>, /* REF50CK1 */
  132. <RZA2_PINMUX(PORTK, 0, 7)>, /* RMMI1_TXDEN */
  133. <RZA2_PINMUX(PORTK, 1, 7)>, /* RMII1_TXD0 */
  134. <RZA2_PINMUX(PORTK, 2, 7)>, /* RMII1_TXD1 */
  135. <RZA2_PINMUX(PORT3, 2, 7)>, /* RMII1_CRSDV */
  136. <RZA2_PINMUX(PORTK, 4, 7)>, /* RMII1_RXD0 */
  137. <RZA2_PINMUX(PORT3, 5, 7)>, /* RMII1_RXD1 */
  138. <RZA2_PINMUX(PORT3, 1, 7)>, /* RMII1_RXER */
  139. <RZA2_PINMUX(PORT3, 3, 1)>, /* ET1_MDC */
  140. <RZA2_PINMUX(PORT3, 4, 1)>, /* ET1_MDIO */
  141. <RZA2_PINMUX(PORTL, 1, 5)>; /* IRQ5 */
  142. };
  143. i2c3_pins: i2c3 {
  144. pinmux = <RZA2_PINMUX(PORTD, 6, 1)>, /* RIIC3SCL */
  145. <RZA2_PINMUX(PORTD, 7, 1)>; /* RIIC3SDA */
  146. };
  147. keyboard_pins: keyboard {
  148. pinmux = <RZA2_PINMUX(PORTJ, 1, 6)>; /* IRQ0 */
  149. };
  150. /* Serial Console */
  151. scif2_pins: serial2 {
  152. pinmux = <RZA2_PINMUX(PORTE, 2, 3)>, /* TxD2 */
  153. <RZA2_PINMUX(PORTE, 1, 3)>; /* RxD2 */
  154. };
  155. sdhi0_pins: sdhi0 {
  156. pinmux = <RZA2_PINMUX(PORT5, 0, 3)>, /* SD0_CD */
  157. <RZA2_PINMUX(PORT5, 1, 3)>; /* SD0_WP */
  158. };
  159. sdhi1_pins: sdhi1 {
  160. pinmux = <RZA2_PINMUX(PORT5, 4, 3)>, /* SD1_CD */
  161. <RZA2_PINMUX(PORT5, 5, 3)>; /* SD1_WP */
  162. };
  163. usb0_pins: usb0 {
  164. pinmux = <RZA2_PINMUX(PORT5, 2, 3)>, /* VBUSIN0 */
  165. <RZA2_PINMUX(PORTC, 6, 1)>, /* VBUSEN0 */
  166. <RZA2_PINMUX(PORTC, 7, 1)>; /* OVRCUR0 */
  167. };
  168. usb1_pins: usb1 {
  169. pinmux = <RZA2_PINMUX(PORTC, 0, 1)>, /* VBUSIN1 */
  170. <RZA2_PINMUX(PORTC, 5, 1)>; /* VBUSEN1 */
  171. };
  172. };
  173. /* RTC_X1 */
  174. &rtc_x1_clk {
  175. clock-frequency = <32768>;
  176. };
  177. /* Serial Console */
  178. &scif2 {
  179. pinctrl-names = "default";
  180. pinctrl-0 = <&scif2_pins>;
  181. status = "okay";
  182. };
  183. &sdhi0 {
  184. pinctrl-names = "default";
  185. pinctrl-0 = <&sdhi0_pins>;
  186. bus-width = <4>;
  187. status = "okay";
  188. };
  189. &sdhi1 {
  190. pinctrl-names = "default";
  191. pinctrl-0 = <&sdhi1_pins>;
  192. bus-width = <4>;
  193. status = "okay";
  194. };
  195. /* USB-0 as Host */
  196. &usb2_phy0 {
  197. pinctrl-names = "default";
  198. pinctrl-0 = <&usb0_pins>;
  199. dr_mode = "host"; /* Requires JP3 to be fitted */
  200. status = "okay";
  201. };
  202. /* USB-1 as Host */
  203. &usb2_phy1 {
  204. pinctrl-names = "default";
  205. pinctrl-0 = <&usb1_pins>;
  206. dr_mode = "host";
  207. status = "okay";
  208. };
  209. /* USB_X1 */
  210. &usb_x1_clk {
  211. clock-frequency = <48000000>;
  212. };