xref: /linux/scripts/dtc/include-prefixes/riscv/starfive/jh7110-starfive-visionfive-2.dtsi (revision 54baba33392d428a8be4942441a92a9b05cf537e)
1*54baba33SEmil Renner Berthing// SPDX-License-Identifier: GPL-2.0 OR MIT
2*54baba33SEmil Renner Berthing/*
3*54baba33SEmil Renner Berthing * Copyright (C) 2022 StarFive Technology Co., Ltd.
4*54baba33SEmil Renner Berthing * Copyright (C) 2022 Emil Renner Berthing <kernel@esmil.dk>
5*54baba33SEmil Renner Berthing */
6*54baba33SEmil Renner Berthing
7*54baba33SEmil Renner Berthing/dts-v1/;
8*54baba33SEmil Renner Berthing#include "jh7110.dtsi"
9*54baba33SEmil Renner Berthing#include "jh7110-pinfunc.h"
10*54baba33SEmil Renner Berthing#include <dt-bindings/gpio/gpio.h>
11*54baba33SEmil Renner Berthing
12*54baba33SEmil Renner Berthing/ {
13*54baba33SEmil Renner Berthing	aliases {
14*54baba33SEmil Renner Berthing		i2c0 = &i2c0;
15*54baba33SEmil Renner Berthing		i2c2 = &i2c2;
16*54baba33SEmil Renner Berthing		i2c5 = &i2c5;
17*54baba33SEmil Renner Berthing		i2c6 = &i2c6;
18*54baba33SEmil Renner Berthing		serial0 = &uart0;
19*54baba33SEmil Renner Berthing	};
20*54baba33SEmil Renner Berthing
21*54baba33SEmil Renner Berthing	chosen {
22*54baba33SEmil Renner Berthing		stdout-path = "serial0:115200n8";
23*54baba33SEmil Renner Berthing	};
24*54baba33SEmil Renner Berthing
25*54baba33SEmil Renner Berthing	cpus {
26*54baba33SEmil Renner Berthing		timebase-frequency = <4000000>;
27*54baba33SEmil Renner Berthing	};
28*54baba33SEmil Renner Berthing
29*54baba33SEmil Renner Berthing	memory@40000000 {
30*54baba33SEmil Renner Berthing		device_type = "memory";
31*54baba33SEmil Renner Berthing		reg = <0x0 0x40000000 0x1 0x0>;
32*54baba33SEmil Renner Berthing	};
33*54baba33SEmil Renner Berthing
34*54baba33SEmil Renner Berthing	gpio-restart {
35*54baba33SEmil Renner Berthing		compatible = "gpio-restart";
36*54baba33SEmil Renner Berthing		gpios = <&sysgpio 35 GPIO_ACTIVE_HIGH>;
37*54baba33SEmil Renner Berthing		priority = <224>;
38*54baba33SEmil Renner Berthing	};
39*54baba33SEmil Renner Berthing};
40*54baba33SEmil Renner Berthing
41*54baba33SEmil Renner Berthing&gmac0_rgmii_rxin {
42*54baba33SEmil Renner Berthing	clock-frequency = <125000000>;
43*54baba33SEmil Renner Berthing};
44*54baba33SEmil Renner Berthing
45*54baba33SEmil Renner Berthing&gmac0_rmii_refin {
46*54baba33SEmil Renner Berthing	clock-frequency = <50000000>;
47*54baba33SEmil Renner Berthing};
48*54baba33SEmil Renner Berthing
49*54baba33SEmil Renner Berthing&gmac1_rgmii_rxin {
50*54baba33SEmil Renner Berthing	clock-frequency = <125000000>;
51*54baba33SEmil Renner Berthing};
52*54baba33SEmil Renner Berthing
53*54baba33SEmil Renner Berthing&gmac1_rmii_refin {
54*54baba33SEmil Renner Berthing	clock-frequency = <50000000>;
55*54baba33SEmil Renner Berthing};
56*54baba33SEmil Renner Berthing
57*54baba33SEmil Renner Berthing&i2srx_bclk_ext {
58*54baba33SEmil Renner Berthing	clock-frequency = <12288000>;
59*54baba33SEmil Renner Berthing};
60*54baba33SEmil Renner Berthing
61*54baba33SEmil Renner Berthing&i2srx_lrck_ext {
62*54baba33SEmil Renner Berthing	clock-frequency = <192000>;
63*54baba33SEmil Renner Berthing};
64*54baba33SEmil Renner Berthing
65*54baba33SEmil Renner Berthing&i2stx_bclk_ext {
66*54baba33SEmil Renner Berthing	clock-frequency = <12288000>;
67*54baba33SEmil Renner Berthing};
68*54baba33SEmil Renner Berthing
69*54baba33SEmil Renner Berthing&i2stx_lrck_ext {
70*54baba33SEmil Renner Berthing	clock-frequency = <192000>;
71*54baba33SEmil Renner Berthing};
72*54baba33SEmil Renner Berthing
73*54baba33SEmil Renner Berthing&mclk_ext {
74*54baba33SEmil Renner Berthing	clock-frequency = <12288000>;
75*54baba33SEmil Renner Berthing};
76*54baba33SEmil Renner Berthing
77*54baba33SEmil Renner Berthing&osc {
78*54baba33SEmil Renner Berthing	clock-frequency = <24000000>;
79*54baba33SEmil Renner Berthing};
80*54baba33SEmil Renner Berthing
81*54baba33SEmil Renner Berthing&rtc_osc {
82*54baba33SEmil Renner Berthing	clock-frequency = <32768>;
83*54baba33SEmil Renner Berthing};
84*54baba33SEmil Renner Berthing
85*54baba33SEmil Renner Berthing&tdm_ext {
86*54baba33SEmil Renner Berthing	clock-frequency = <49152000>;
87*54baba33SEmil Renner Berthing};
88*54baba33SEmil Renner Berthing
89*54baba33SEmil Renner Berthing&i2c0 {
90*54baba33SEmil Renner Berthing	clock-frequency = <100000>;
91*54baba33SEmil Renner Berthing	i2c-sda-hold-time-ns = <300>;
92*54baba33SEmil Renner Berthing	i2c-sda-falling-time-ns = <510>;
93*54baba33SEmil Renner Berthing	i2c-scl-falling-time-ns = <510>;
94*54baba33SEmil Renner Berthing	pinctrl-names = "default";
95*54baba33SEmil Renner Berthing	pinctrl-0 = <&i2c0_pins>;
96*54baba33SEmil Renner Berthing	status = "okay";
97*54baba33SEmil Renner Berthing};
98*54baba33SEmil Renner Berthing
99*54baba33SEmil Renner Berthing&i2c2 {
100*54baba33SEmil Renner Berthing	clock-frequency = <100000>;
101*54baba33SEmil Renner Berthing	i2c-sda-hold-time-ns = <300>;
102*54baba33SEmil Renner Berthing	i2c-sda-falling-time-ns = <510>;
103*54baba33SEmil Renner Berthing	i2c-scl-falling-time-ns = <510>;
104*54baba33SEmil Renner Berthing	pinctrl-names = "default";
105*54baba33SEmil Renner Berthing	pinctrl-0 = <&i2c2_pins>;
106*54baba33SEmil Renner Berthing	status = "okay";
107*54baba33SEmil Renner Berthing};
108*54baba33SEmil Renner Berthing
109*54baba33SEmil Renner Berthing&i2c5 {
110*54baba33SEmil Renner Berthing	clock-frequency = <100000>;
111*54baba33SEmil Renner Berthing	i2c-sda-hold-time-ns = <300>;
112*54baba33SEmil Renner Berthing	i2c-sda-falling-time-ns = <510>;
113*54baba33SEmil Renner Berthing	i2c-scl-falling-time-ns = <510>;
114*54baba33SEmil Renner Berthing	pinctrl-names = "default";
115*54baba33SEmil Renner Berthing	pinctrl-0 = <&i2c5_pins>;
116*54baba33SEmil Renner Berthing	status = "okay";
117*54baba33SEmil Renner Berthing};
118*54baba33SEmil Renner Berthing
119*54baba33SEmil Renner Berthing&i2c6 {
120*54baba33SEmil Renner Berthing	clock-frequency = <100000>;
121*54baba33SEmil Renner Berthing	i2c-sda-hold-time-ns = <300>;
122*54baba33SEmil Renner Berthing	i2c-sda-falling-time-ns = <510>;
123*54baba33SEmil Renner Berthing	i2c-scl-falling-time-ns = <510>;
124*54baba33SEmil Renner Berthing	pinctrl-names = "default";
125*54baba33SEmil Renner Berthing	pinctrl-0 = <&i2c6_pins>;
126*54baba33SEmil Renner Berthing	status = "okay";
127*54baba33SEmil Renner Berthing};
128*54baba33SEmil Renner Berthing
129*54baba33SEmil Renner Berthing&sysgpio {
130*54baba33SEmil Renner Berthing	i2c0_pins: i2c0-0 {
131*54baba33SEmil Renner Berthing		i2c-pins {
132*54baba33SEmil Renner Berthing			pinmux = <GPIOMUX(57, GPOUT_LOW,
133*54baba33SEmil Renner Berthing					      GPOEN_SYS_I2C0_CLK,
134*54baba33SEmil Renner Berthing					      GPI_SYS_I2C0_CLK)>,
135*54baba33SEmil Renner Berthing				 <GPIOMUX(58, GPOUT_LOW,
136*54baba33SEmil Renner Berthing					      GPOEN_SYS_I2C0_DATA,
137*54baba33SEmil Renner Berthing					      GPI_SYS_I2C0_DATA)>;
138*54baba33SEmil Renner Berthing			bias-disable; /* external pull-up */
139*54baba33SEmil Renner Berthing			input-enable;
140*54baba33SEmil Renner Berthing			input-schmitt-enable;
141*54baba33SEmil Renner Berthing		};
142*54baba33SEmil Renner Berthing	};
143*54baba33SEmil Renner Berthing
144*54baba33SEmil Renner Berthing	i2c2_pins: i2c2-0 {
145*54baba33SEmil Renner Berthing		i2c-pins {
146*54baba33SEmil Renner Berthing			pinmux = <GPIOMUX(3, GPOUT_LOW,
147*54baba33SEmil Renner Berthing					     GPOEN_SYS_I2C2_CLK,
148*54baba33SEmil Renner Berthing					     GPI_SYS_I2C2_CLK)>,
149*54baba33SEmil Renner Berthing				 <GPIOMUX(2, GPOUT_LOW,
150*54baba33SEmil Renner Berthing					     GPOEN_SYS_I2C2_DATA,
151*54baba33SEmil Renner Berthing					     GPI_SYS_I2C2_DATA)>;
152*54baba33SEmil Renner Berthing			bias-disable; /* external pull-up */
153*54baba33SEmil Renner Berthing			input-enable;
154*54baba33SEmil Renner Berthing			input-schmitt-enable;
155*54baba33SEmil Renner Berthing		};
156*54baba33SEmil Renner Berthing	};
157*54baba33SEmil Renner Berthing
158*54baba33SEmil Renner Berthing	i2c5_pins: i2c5-0 {
159*54baba33SEmil Renner Berthing		i2c-pins {
160*54baba33SEmil Renner Berthing			pinmux = <GPIOMUX(19, GPOUT_LOW,
161*54baba33SEmil Renner Berthing					      GPOEN_SYS_I2C5_CLK,
162*54baba33SEmil Renner Berthing					      GPI_SYS_I2C5_CLK)>,
163*54baba33SEmil Renner Berthing				 <GPIOMUX(20, GPOUT_LOW,
164*54baba33SEmil Renner Berthing					      GPOEN_SYS_I2C5_DATA,
165*54baba33SEmil Renner Berthing					      GPI_SYS_I2C5_DATA)>;
166*54baba33SEmil Renner Berthing			bias-disable; /* external pull-up */
167*54baba33SEmil Renner Berthing			input-enable;
168*54baba33SEmil Renner Berthing			input-schmitt-enable;
169*54baba33SEmil Renner Berthing		};
170*54baba33SEmil Renner Berthing	};
171*54baba33SEmil Renner Berthing
172*54baba33SEmil Renner Berthing	i2c6_pins: i2c6-0 {
173*54baba33SEmil Renner Berthing		i2c-pins {
174*54baba33SEmil Renner Berthing			pinmux = <GPIOMUX(16, GPOUT_LOW,
175*54baba33SEmil Renner Berthing					      GPOEN_SYS_I2C6_CLK,
176*54baba33SEmil Renner Berthing					      GPI_SYS_I2C6_CLK)>,
177*54baba33SEmil Renner Berthing				 <GPIOMUX(17, GPOUT_LOW,
178*54baba33SEmil Renner Berthing					      GPOEN_SYS_I2C6_DATA,
179*54baba33SEmil Renner Berthing					      GPI_SYS_I2C6_DATA)>;
180*54baba33SEmil Renner Berthing			bias-disable; /* external pull-up */
181*54baba33SEmil Renner Berthing			input-enable;
182*54baba33SEmil Renner Berthing			input-schmitt-enable;
183*54baba33SEmil Renner Berthing		};
184*54baba33SEmil Renner Berthing	};
185*54baba33SEmil Renner Berthing
186*54baba33SEmil Renner Berthing	uart0_pins: uart0-0 {
187*54baba33SEmil Renner Berthing		tx-pins {
188*54baba33SEmil Renner Berthing			pinmux = <GPIOMUX(5, GPOUT_SYS_UART0_TX,
189*54baba33SEmil Renner Berthing					     GPOEN_ENABLE,
190*54baba33SEmil Renner Berthing					     GPI_NONE)>;
191*54baba33SEmil Renner Berthing			bias-disable;
192*54baba33SEmil Renner Berthing			drive-strength = <12>;
193*54baba33SEmil Renner Berthing			input-disable;
194*54baba33SEmil Renner Berthing			input-schmitt-disable;
195*54baba33SEmil Renner Berthing			slew-rate = <0>;
196*54baba33SEmil Renner Berthing		};
197*54baba33SEmil Renner Berthing
198*54baba33SEmil Renner Berthing		rx-pins {
199*54baba33SEmil Renner Berthing			pinmux = <GPIOMUX(6, GPOUT_LOW,
200*54baba33SEmil Renner Berthing					     GPOEN_DISABLE,
201*54baba33SEmil Renner Berthing					     GPI_SYS_UART0_RX)>;
202*54baba33SEmil Renner Berthing			bias-disable; /* external pull-up */
203*54baba33SEmil Renner Berthing			drive-strength = <2>;
204*54baba33SEmil Renner Berthing			input-enable;
205*54baba33SEmil Renner Berthing			input-schmitt-enable;
206*54baba33SEmil Renner Berthing			slew-rate = <0>;
207*54baba33SEmil Renner Berthing		};
208*54baba33SEmil Renner Berthing	};
209*54baba33SEmil Renner Berthing};
210*54baba33SEmil Renner Berthing
211*54baba33SEmil Renner Berthing&uart0 {
212*54baba33SEmil Renner Berthing	pinctrl-names = "default";
213*54baba33SEmil Renner Berthing	pinctrl-0 = <&uart0_pins>;
214*54baba33SEmil Renner Berthing	status = "okay";
215*54baba33SEmil Renner Berthing};
216