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