hifive-unleashed-a00.dts 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141
  1. // SPDX-License-Identifier: (GPL-2.0 OR MIT)
  2. /* Copyright (c) 2018-2019 SiFive, Inc */
  3. #include "fu540-c000.dtsi"
  4. #include <dt-bindings/gpio/gpio.h>
  5. #include <dt-bindings/leds/common.h>
  6. #include <dt-bindings/pwm/pwm.h>
  7. /* Clock frequency (in Hz) of the PCB crystal for rtcclk */
  8. #define RTCCLK_FREQ 1000000
  9. / {
  10. model = "SiFive HiFive Unleashed A00";
  11. compatible = "sifive,hifive-unleashed-a00", "sifive,fu540-c000",
  12. "sifive,fu540";
  13. chosen {
  14. stdout-path = "serial0";
  15. };
  16. cpus {
  17. timebase-frequency = <RTCCLK_FREQ>;
  18. };
  19. memory@80000000 {
  20. device_type = "memory";
  21. reg = <0x0 0x80000000 0x2 0x00000000>;
  22. };
  23. hfclk: hfclk {
  24. #clock-cells = <0>;
  25. compatible = "fixed-clock";
  26. clock-frequency = <33333333>;
  27. clock-output-names = "hfclk";
  28. };
  29. rtcclk: rtcclk {
  30. #clock-cells = <0>;
  31. compatible = "fixed-clock";
  32. clock-frequency = <RTCCLK_FREQ>;
  33. clock-output-names = "rtcclk";
  34. };
  35. gpio-restart {
  36. compatible = "gpio-restart";
  37. gpios = <&gpio 10 GPIO_ACTIVE_LOW>;
  38. };
  39. led-controller {
  40. compatible = "pwm-leds";
  41. led-d1 {
  42. pwms = <&pwm0 0 7812500 PWM_POLARITY_INVERTED>;
  43. active-low;
  44. color = <LED_COLOR_ID_GREEN>;
  45. max-brightness = <255>;
  46. label = "d1";
  47. };
  48. led-d2 {
  49. pwms = <&pwm0 1 7812500 PWM_POLARITY_INVERTED>;
  50. active-low;
  51. color = <LED_COLOR_ID_GREEN>;
  52. max-brightness = <255>;
  53. label = "d2";
  54. };
  55. led-d3 {
  56. pwms = <&pwm0 2 7812500 PWM_POLARITY_INVERTED>;
  57. active-low;
  58. color = <LED_COLOR_ID_GREEN>;
  59. max-brightness = <255>;
  60. label = "d3";
  61. };
  62. led-d4 {
  63. pwms = <&pwm0 3 7812500 PWM_POLARITY_INVERTED>;
  64. active-low;
  65. color = <LED_COLOR_ID_GREEN>;
  66. max-brightness = <255>;
  67. label = "d4";
  68. };
  69. };
  70. };
  71. &uart0 {
  72. status = "okay";
  73. };
  74. &uart1 {
  75. status = "okay";
  76. };
  77. &i2c0 {
  78. status = "okay";
  79. };
  80. &qspi0 {
  81. status = "okay";
  82. flash@0 {
  83. compatible = "jedec,spi-nor";
  84. reg = <0>;
  85. spi-max-frequency = <50000000>;
  86. m25p,fast-read;
  87. spi-tx-bus-width = <4>;
  88. spi-rx-bus-width = <4>;
  89. };
  90. };
  91. &qspi2 {
  92. status = "okay";
  93. mmc@0 {
  94. compatible = "mmc-spi-slot";
  95. reg = <0>;
  96. spi-max-frequency = <20000000>;
  97. voltage-ranges = <3300 3300>;
  98. disable-wp;
  99. gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
  100. };
  101. };
  102. &eth0 {
  103. status = "okay";
  104. phy-mode = "gmii";
  105. phy-handle = <&phy0>;
  106. phy0: ethernet-phy@0 {
  107. compatible = "ethernet-phy-id0007.0771";
  108. reg = <0>;
  109. };
  110. };
  111. &pwm0 {
  112. status = "okay";
  113. };
  114. &pwm1 {
  115. status = "okay";
  116. };
  117. &gpio {
  118. status = "okay";
  119. };