1// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2/*
3 * DTS for Emlid Neutis N5 Dev board.
4 *
5 * Copyright (C) 2018 Aleksandr Aleksandrov <aleksandr.aleksandrov@emlid.com>
6 */
7
8/dts-v1/;
9
10#include "sun50i-h5-emlid-neutis-n5.dtsi"
11
12/ {
13	model = "Emlid Neutis N5 Developer board";
14	compatible = "emlid,neutis-n5-devboard",
15		     "emlid,neutis-n5",
16		     "allwinner,sun50i-h5";
17
18	aliases {
19		serial0 = &uart0;
20	};
21
22	chosen {
23		stdout-path = "serial0:115200n8";
24	};
25
26	connector {
27		compatible = "hdmi-connector";
28		type = "a";
29
30		port {
31			hdmi_con_in: endpoint {
32				remote-endpoint = <&hdmi_out_con>;
33			};
34		};
35	};
36
37	reg_usb0_vbus: usb0-vbus {
38		compatible = "regulator-fixed";
39		regulator-name = "usb0-vbus";
40		regulator-min-microvolt = <5000000>;
41		regulator-max-microvolt = <5000000>;
42		enable-active-high;
43		gpio = <&r_pio 0 9 GPIO_ACTIVE_HIGH>;   /* PL9 */
44		status = "okay";
45	};
46
47	vdd_cpux: gpio-regulator {
48		compatible = "regulator-gpio";
49		pinctrl-names = "default";
50		regulator-name = "vdd-cpux";
51		regulator-type = "voltage";
52		regulator-boot-on;
53		regulator-always-on;
54		regulator-min-microvolt = <1100000>;
55		regulator-max-microvolt = <1300000>;
56		regulator-ramp-delay = <50>; /* 4ms */
57		gpios = <&r_pio 0 6 GPIO_ACTIVE_HIGH>; /* PL6 */
58		gpios-states = <0x1>;
59		states = <1100000 0x0
60			  1300000 0x1>;
61	};
62};
63
64&codec {
65	allwinner,audio-routing =
66		"Line Out", "LINEOUT",
67		"LINEIN", "Line In",
68		"MIC1", "Mic",
69		"MIC2", "Mic",
70		"Mic",  "MBIAS";
71	status = "okay";
72};
73
74&de {
75	status = "okay";
76};
77
78&ehci0 {
79	status = "okay";
80};
81
82&ehci1 {
83	status = "okay";
84};
85
86&ehci2 {
87	status = "okay";
88};
89
90&ehci3 {
91	status = "okay";
92};
93
94&emac {
95	phy-handle = <&int_mii_phy>;
96	phy-mode = "mii";
97	allwinner,leds-active-low;
98	status = "okay";
99};
100
101&hdmi {
102	status = "okay";
103};
104
105&hdmi_out {
106	hdmi_out_con: endpoint {
107		remote-endpoint = <&hdmi_con_in>;
108	};
109};
110
111&mmc0 {
112	vmmc-supply = <&reg_vcc3v3>;
113	bus-width = <4>;
114	cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>; /* PF6 */
115	status = "okay";
116};
117
118&ohci0 {
119	status = "okay";
120};
121
122&ohci1 {
123	status = "okay";
124};
125
126&ohci2 {
127	status = "okay";
128};
129
130&ohci3 {
131	status = "okay";
132};
133
134&uart0 {
135	pinctrl-names = "default";
136	pinctrl-0 = <&uart0_pins_a>;
137	status = "okay";
138};
139
140&usb_otg {
141	dr_mode = "otg";
142	status = "okay";
143};
144
145&usbphy {
146	usb0_id_det-gpios = <&r_pio 0 8 GPIO_ACTIVE_HIGH>; /* PL8 */
147	usb0_vbus-supply = <&reg_usb0_vbus>;
148	status = "okay";
149};
150