lan966x-pcb8309.dts 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216
  1. // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
  2. /*
  3. * lan966x_pcb8309.dts - Device Tree file for PCB8309
  4. */
  5. /dts-v1/;
  6. #include "lan966x.dtsi"
  7. #include "dt-bindings/phy/phy-lan966x-serdes.h"
  8. / {
  9. model = "Microchip EVB - LAN9662";
  10. compatible = "microchip,lan9662-pcb8309", "microchip,lan9662", "microchip,lan966";
  11. aliases {
  12. serial0 = &usart3;
  13. i2c102 = &i2c102;
  14. i2c103 = &i2c103;
  15. };
  16. chosen {
  17. stdout-path = "serial0:115200n8";
  18. };
  19. gpio-restart {
  20. compatible = "gpio-restart";
  21. gpios = <&gpio 56 GPIO_ACTIVE_LOW>;
  22. priority = <200>;
  23. };
  24. i2c-mux {
  25. compatible = "i2c-mux";
  26. #address-cells = <1>;
  27. #size-cells = <0>;
  28. mux-controls = <&mux>;
  29. i2c-parent = <&i2c4>;
  30. i2c102: i2c-sfp@1 {
  31. reg = <1>;
  32. };
  33. i2c103: i2c-sfp@2 {
  34. reg = <2>;
  35. };
  36. };
  37. leds {
  38. compatible = "gpio-leds";
  39. led-s0-green {
  40. label = "s0:green";
  41. gpios = <&sgpio_out 2 0 GPIO_ACTIVE_LOW>;
  42. default-state = "off";
  43. };
  44. led-s0-red {
  45. label = "s0:red";
  46. gpios = <&sgpio_out 2 1 GPIO_ACTIVE_LOW>;
  47. default-state = "off";
  48. };
  49. led-s1-green {
  50. label = "s1:green";
  51. gpios = <&sgpio_out 3 0 GPIO_ACTIVE_LOW>;
  52. default-state = "off";
  53. };
  54. led-s1-red {
  55. label = "s1:red";
  56. gpios = <&sgpio_out 3 1 GPIO_ACTIVE_LOW>;
  57. default-state = "off";
  58. };
  59. };
  60. mux: mux-controller {
  61. compatible = "gpio-mux";
  62. #mux-control-cells = <0>;
  63. mux-gpios = <&sgpio_out 11 0 GPIO_ACTIVE_HIGH>, /* p11b0 */
  64. <&sgpio_out 11 1 GPIO_ACTIVE_HIGH>; /* p11b1 */
  65. };
  66. sfp2: sfp2 {
  67. compatible = "sff,sfp";
  68. i2c-bus = <&i2c102>;
  69. tx-disable-gpios = <&sgpio_out 10 0 GPIO_ACTIVE_LOW>;
  70. los-gpios = <&sgpio_in 2 0 GPIO_ACTIVE_HIGH>;
  71. mod-def0-gpios = <&sgpio_in 2 1 GPIO_ACTIVE_LOW>;
  72. tx-fault-gpios = <&sgpio_in 1 0 GPIO_ACTIVE_HIGH>;
  73. };
  74. sfp3: sfp3 {
  75. compatible = "sff,sfp";
  76. i2c-bus = <&i2c103>;
  77. tx-disable-gpios = <&sgpio_out 10 1 GPIO_ACTIVE_LOW>;
  78. los-gpios = <&sgpio_in 3 0 GPIO_ACTIVE_HIGH>;
  79. mod-def0-gpios = <&sgpio_in 3 1 GPIO_ACTIVE_LOW>;
  80. tx-fault-gpios = <&sgpio_in 1 1 GPIO_ACTIVE_HIGH>;
  81. };
  82. };
  83. &aes {
  84. status = "disabled"; /* Reserved by secure OS */
  85. };
  86. &flx3 {
  87. atmel,flexcom-mode = <ATMEL_FLEXCOM_MODE_USART>;
  88. status = "okay";
  89. usart3: serial@200 {
  90. pinctrl-0 = <&fc3_b_pins>;
  91. pinctrl-names = "default";
  92. status = "okay";
  93. };
  94. };
  95. &flx4 {
  96. atmel,flexcom-mode = <ATMEL_FLEXCOM_MODE_TWI>;
  97. status = "okay";
  98. i2c4: i2c@600 {
  99. compatible = "microchip,sam9x60-i2c";
  100. reg = <0x600 0x200>;
  101. interrupts = <GIC_SPI 52 IRQ_TYPE_LEVEL_HIGH>;
  102. clocks = <&nic_clk>;
  103. pinctrl-0 = <&fc4_b_pins>;
  104. pinctrl-names = "default";
  105. i2c-analog-filter;
  106. i2c-digital-filter;
  107. i2c-digital-filter-width-ns = <35>;
  108. i2c-sda-hold-time-ns = <1500>;
  109. status = "okay";
  110. };
  111. };
  112. &gpio {
  113. fc3_b_pins: fc3-b-pins {
  114. /* RXD, TXD */
  115. pins = "GPIO_52", "GPIO_53";
  116. function = "fc3_b";
  117. };
  118. fc4_b_pins: fc4-b-pins {
  119. /* SCL, SDA */
  120. pins = "GPIO_57", "GPIO_58";
  121. function = "fc4_b";
  122. };
  123. sgpio_a_pins: sgpio-a-pins {
  124. /* SCK, D0, D1, LD */
  125. pins = "GPIO_32", "GPIO_33", "GPIO_34", "GPIO_35";
  126. function = "sgpio_a";
  127. };
  128. };
  129. &mdio1 {
  130. status = "okay";
  131. };
  132. &phy0 {
  133. status = "okay";
  134. };
  135. &phy1 {
  136. status = "okay";
  137. };
  138. &port0 {
  139. phy-handle = <&phy0>;
  140. phy-mode = "gmii";
  141. phys = <&serdes 0 CU(0)>;
  142. status = "okay";
  143. };
  144. &port1 {
  145. phy-handle = <&phy1>;
  146. phy-mode = "gmii";
  147. phys = <&serdes 1 CU(1)>;
  148. status = "okay";
  149. };
  150. &port2 {
  151. sfp = <&sfp2>;
  152. managed = "in-band-status";
  153. phy-mode = "sgmii";
  154. phys = <&serdes 2 SERDES6G(0)>;
  155. status = "okay";
  156. };
  157. &port3 {
  158. sfp = <&sfp3>;
  159. managed = "in-band-status";
  160. phy-mode = "sgmii";
  161. phys = <&serdes 3 SERDES6G(1)>;
  162. status = "okay";
  163. };
  164. &serdes {
  165. status = "okay";
  166. };
  167. &sgpio {
  168. pinctrl-0 = <&sgpio_a_pins>;
  169. pinctrl-names = "default";
  170. microchip,sgpio-port-ranges = <0 3>, <8 11>;
  171. status = "okay";
  172. gpio@0 {
  173. ngpios = <64>;
  174. };
  175. gpio@1 {
  176. ngpios = <64>;
  177. };
  178. };
  179. &switch {
  180. status = "okay";
  181. };