hihope-common.dtsi 5.0 KB
Newer Older
1 2 3 4 5 6 7
// SPDX-License-Identifier: GPL-2.0
/*
 * Device Tree Source for the HiHope RZ/G2[MN] main board common parts
 *
 * Copyright (C) 2019 Renesas Electronics Corp.
 */

8 9
#include <dt-bindings/gpio/gpio.h>

10 11 12 13 14 15 16 17 18
/ {
	aliases {
		serial0 = &scif2;
	};

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

20 21 22 23 24 25 26 27 28 29 30
	hdmi0-out {
		compatible = "hdmi-connector";
		type = "a";

		port {
			hdmi0_con: endpoint {
				remote-endpoint = <&rcar_dw_hdmi0_out>;
			};
		};
	};

31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50
	leds {
		compatible = "gpio-leds";

		led0 {
			gpios = <&gpio6 11 GPIO_ACTIVE_HIGH>;
		};

		led1 {
			gpios = <&gpio6 12 GPIO_ACTIVE_HIGH>;
		};

		led2 {
			gpios = <&gpio6 13 GPIO_ACTIVE_HIGH>;
		};

		led3 {
			gpios = <&gpio0  0 GPIO_ACTIVE_HIGH>;
		};
	};

51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68
	reg_1p8v: regulator0 {
		compatible = "regulator-fixed";
		regulator-name = "fixed-1.8V";
		regulator-min-microvolt = <1800000>;
		regulator-max-microvolt = <1800000>;
		regulator-boot-on;
		regulator-always-on;
	};

	reg_3p3v: regulator1 {
		compatible = "regulator-fixed";
		regulator-name = "fixed-3.3V";
		regulator-min-microvolt = <3300000>;
		regulator-max-microvolt = <3300000>;
		regulator-boot-on;
		regulator-always-on;
	};

69 70 71 72 73 74 75 76 77 78 79
	vbus0_usb2: regulator-vbus0-usb2 {
		compatible = "regulator-fixed";

		regulator-name = "USB20_VBUS0";
		regulator-min-microvolt = <5000000>;
		regulator-max-microvolt = <5000000>;

		gpio = <&gpio6 16 GPIO_ACTIVE_HIGH>;
		enable-active-high;
	};

80 81 82 83 84 85 86 87 88 89 90 91
	vccq_sdhi0: regulator-vccq-sdhi0 {
		compatible = "regulator-gpio";

		regulator-name = "SDHI0 VccQ";
		regulator-min-microvolt = <1800000>;
		regulator-max-microvolt = <3300000>;

		gpios = <&gpio6 30 GPIO_ACTIVE_HIGH>;
		gpios-states = <1>;
		states = <3300000 1
			  1800000 0>;
	};
92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115

	x302_clk: x302-clock {
		compatible = "fixed-clock";
		#clock-cells = <0>;
		clock-frequency = <33000000>;
	};

	x304_clk: x304-clock {
		compatible = "fixed-clock";
		#clock-cells = <0>;
		clock-frequency = <25000000>;
	};
};

&du {
	clocks = <&cpg CPG_MOD 724>,
		 <&cpg CPG_MOD 723>,
		 <&cpg CPG_MOD 722>,
		 <&versaclock5 1>,
		 <&x302_clk>,
		 <&versaclock5 2>;
	clock-names = "du.0", "du.1", "du.2",
		      "dclkin.0", "dclkin.1", "dclkin.2";
	status = "okay";
116 117
};

118 119 120 121 122 123 124 125
&ehci0 {
	status = "okay";
};

&ehci1 {
	status = "okay";
};

126 127 128 129 130 131 132 133
&extal_clk {
	clock-frequency = <16666666>;
};

&extalr_clk {
	clock-frequency = <32768>;
};

134 135 136 137 138 139 140 141 142
&gpio6 {
	usb1-reset {
		gpio-hog;
		gpios = <10 GPIO_ACTIVE_LOW>;
		output-low;
		line-name = "usb1-reset";
	};
};

143 144 145 146 147 148 149 150 151 152 153 154 155
&hdmi0 {
	status = "okay";

	ports {
		port@1 {
			reg = <1>;
			rcar_dw_hdmi0_out: endpoint {
				remote-endpoint = <&hdmi0_con>;
			};
		};
	};
};

156 157 158 159 160
&hsusb {
	dr_mode = "otg";
	status = "okay";
};

161 162 163 164 165 166 167 168 169 170 171 172 173
&i2c4 {
	clock-frequency = <400000>;
	status = "okay";

	versaclock5: clock-generator@6a {
		compatible = "idt,5p49v5923";
		reg = <0x6a>;
		#clock-cells = <1>;
		clocks = <&x304_clk>;
		clock-names = "xin";
	};
};

174 175 176 177 178 179 180 181
&ohci0 {
	status = "okay";
};

&ohci1 {
	status = "okay";
};

182 183 184 185
&pcie_bus_clk {
	clock-frequency = <100000000>;
};

186 187 188 189 190 191 192 193 194 195 196 197 198
&pfc {
	pinctrl-0 = <&scif_clk_pins>;
	pinctrl-names = "default";

	scif2_pins: scif2 {
		groups = "scif2_data_a";
		function = "scif2";
	};

	scif_clk_pins: scif_clk {
		groups = "scif_clk_a";
		function = "scif_clk";
	};
199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216

	sdhi0_pins: sd0 {
		groups = "sdhi0_data4", "sdhi0_ctrl";
		function = "sdhi0";
		power-source = <3300>;
	};

	sdhi0_pins_uhs: sd0_uhs {
		groups = "sdhi0_data4", "sdhi0_ctrl";
		function = "sdhi0";
		power-source = <1800>;
	};

	sdhi3_pins: sd3 {
		groups = "sdhi3_data8", "sdhi3_ctrl", "sdhi3_ds";
		function = "sdhi3";
		power-source = <1800>;
	};
217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233

	usb0_pins: usb0 {
		groups = "usb0";
		function = "usb0";
	};

	usb1_pins: usb1 {
		mux {
			groups = "usb1";
			function = "usb1";
		};

		ovc {
			pins = "GP_6_27";
			bias-pull-up;
		};
	};
234 235 236 237 238

	usb30_pins: usb30 {
		groups = "usb30";
		function = "usb30";
	};
239 240
};

241 242 243 244 245
&rwdt {
	timeout-sec = <60>;
	status = "okay";
};

246
&scif2 {
247 248 249
	pinctrl-0 = <&scif2_pins>;
	pinctrl-names = "default";

250 251 252 253 254 255
	status = "okay";
};

&scif_clk {
	clock-frequency = <14745600>;
};
256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281

&sdhi0 {
	pinctrl-0 = <&sdhi0_pins>;
	pinctrl-1 = <&sdhi0_pins_uhs>;
	pinctrl-names = "default", "state_uhs";

	vmmc-supply = <&reg_3p3v>;
	vqmmc-supply = <&vccq_sdhi0>;
	cd-gpios = <&gpio3 12 GPIO_ACTIVE_LOW>;
	bus-width = <4>;
	sd-uhs-sdr50;
	sd-uhs-sdr104;
	status = "okay";
};

&sdhi3 {
	pinctrl-0 = <&sdhi3_pins>;
	pinctrl-1 = <&sdhi3_pins>;
	pinctrl-names = "default", "state_uhs";

	vmmc-supply = <&reg_3p3v>;
	vqmmc-supply = <&reg_1p8v>;
	bus-width = <8>;
	mmc-hs200-1_8v;
	non-removable;
	fixed-emmc-driver-type = <1>;
282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299
};

&usb_extal_clk {
	clock-frequency = <50000000>;
};

&usb2_phy0 {
	pinctrl-0 = <&usb0_pins>;
	pinctrl-names = "default";

	vbus-supply = <&vbus0_usb2>;
	status = "okay";
};

&usb2_phy1 {
	pinctrl-0 = <&usb1_pins>;
	pinctrl-names = "default";

300 301
	status = "okay";
};
302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325

&usb3_peri0 {
	phys = <&usb3_phy0>;
	phy-names = "usb";

	companion = <&xhci0>;

	status = "okay";
};

&usb3_phy0 {
	status = "okay";
};

&usb3s0_clk {
	clock-frequency = <100000000>;
};

&xhci0 {
	pinctrl-0 = <&usb30_pins>;
	pinctrl-names = "default";

	status = "okay";
};