summaryrefslogtreecommitdiff
path: root/arch/arm/dts/armada-3720-turris-mox.dts
blob: 8e0ebf508d4483f229e2ba222d60f934e0ce781c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
// SPDX-License-Identifier: GPL-2.0+ or X11
/*
 * Device Tree file for CZ.NIC Turris Mox Board
 * 2018 by Marek Behun <marek.behun@nic.cz>
 *
 * Based on armada-3720-espressobin.dts by:
 *   Gregory CLEMENT <gregory.clement@free-electrons.com>
 *   Konstantin Porotchkin <kostap@marvell.com>
 */

/dts-v1/;

#include <dt-bindings/gpio/gpio.h>
#include "armada-372x.dtsi"

/ {
	model = "CZ.NIC Turris Mox Board";
	compatible = "cznic,turris-mox", "marvell,armada3720",
		     "marvell,armada3710";

	chosen {
		stdout-path = "serial0:115200n8";
	};

	aliases {
		ethernet0 = &eth0;
		ethernet1 = &eth1;
		i2c0 = &i2c0;
		spi0 = &spi0;
	};

	memory {
		device_type = "memory";
		reg = <0x00000000 0x00000000 0x00000000 0x20000000>;
	};

	reg_usb3_vbus: usb3_vbus@0 {
		compatible = "regulator-fixed";
		regulator-name = "usb3-vbus";
		regulator-min-microvolt = <5000000>;
		regulator-max-microvolt = <5000000>;
		startup-delay-us = <2000000>;
		shutdown-delay-us = <1000000>;
		gpio = <&gpiosb 0 GPIO_ACTIVE_HIGH>;
		enable-active-high;
		regulator-boot-on;
	};

	vsdc_reg: vsdc-reg {
		compatible = "regulator-gpio";
		regulator-name = "vsdc";
		regulator-min-microvolt = <1800000>;
		regulator-max-microvolt = <3300000>;
		regulator-boot-on;

		gpios = <&gpiosb 23 GPIO_ACTIVE_HIGH>;
		gpios-states = <0>;
		states = <1800000 0x1
			  3300000 0x0>;
		enable-active-high;
	};

	mdio {
		#address-cells = <1>;
		#size-cells = <0>;

		eth_phy1: ethernet-phy@1 {
			reg = <1>;
		};
	};
};

&comphy {
	max-lanes = <3>;
	phy0 {
		phy-type = <COMPHY_TYPE_SGMII1>;
		phy-speed = <COMPHY_SPEED_3_125G>;
	};

	phy1 {
		phy-type = <COMPHY_TYPE_PEX0>;
		phy-speed = <COMPHY_SPEED_5G>;
	};

	phy2 {
		phy-type = <COMPHY_TYPE_USB3_HOST0>;
		phy-speed = <COMPHY_SPEED_5G>;
	};
};

&eth0 {
	status = "okay";
	pinctrl-names = "default";
	pinctrl-0 = <&rgmii_pins>, <&smi_pins>;
	phy-mode = "rgmii";
	phy = <&eth_phy1>;
};

&i2c0 {
	pinctrl-names = "default";
	pinctrl-0 = <&i2c1_pins>;
	status = "okay";
	#address-cells = <1>;
	#size-cells = <0>;

	rtc@6f {
		compatible = "microchip,mcp7941x";
		reg = <0x6f>;
	};
};

&sdhci1 {
	wp-inverted;
	bus-width = <4>;
	cd-gpios = <&gpionb 10 GPIO_ACTIVE_HIGH>;
	vqmmc-supply = <&vsdc_reg>;
	marvell,pad-type = "sd";
	status = "okay";
};

&pinctrl_nb {
	spi_cs1_pins: spi-cs1-pins {
		groups = "spi_cs1";
		function = "spi";
	};
};

&spi0 {
	status = "okay";
	pinctrl-names = "default";
	pinctrl-0 = <&spi_cs1_pins>;
	assigned-clocks = <&nb_periph_clk 7>;
	assigned-clock-parents = <&tbg 1>;
	assigned-clock-rates = <20000000>;

	spi-flash@0 {
		#address-cells = <1>;
		#size-cells = <1>;
		compatible = "st,s25fl064l", "jedec,spi-nor";
		reg = <0>;
		spi-max-frequency = <20000000>;
		m25p,fast-read;
	};

	moxtet@1 {
		#address-cells = <1>;
		#size-cells = <0>;
		compatible = "cznic,moxtet";
		reg = <1>;
		reset-gpios = <&gpiosb 2 GPIO_ACTIVE_LOW>;
		spi-max-frequency = <1000000>;
		spi-cpol;
		spi-cpha;
	};
};

&uart0 {
	pinctrl-names = "default";
	pinctrl-0 = <&uart1_pins>;
	status = "okay";
};

&usb2 {
	status = "okay";
};

&usb3 {
	vbus-supply = <&reg_usb3_vbus>;
	status = "okay";
};

&pcie0 {
	pinctrl-names = "default";
	pinctrl-0 = <&pcie_pins>;
	reset-gpios = <&gpiosb 3 GPIO_ACTIVE_LOW>;
	status = "disabled";
};