1// SPDX-License-Identifier: GPL-2.0+ OR MIT
2/*
3 * Copyright 2016-2020 Toradex
4 */
5
6/ {
7	/* Fixed crystal dedicated to MCP2515. */
8	clk16m: clk16m {
9		compatible = "fixed-clock";
10		#clock-cells = <0>;
11		clock-frequency = <16000000>;
12	};
13
14	reg_3v3: regulator-3v3 {
15		compatible = "regulator-fixed";
16		regulator-name = "3.3V";
17		regulator-min-microvolt = <3300000>;
18		regulator-max-microvolt = <3300000>;
19	};
20
21	reg_5v0: regulator-5v0 {
22		compatible = "regulator-fixed";
23		regulator-name = "5V";
24		regulator-min-microvolt = <5000000>;
25		regulator-max-microvolt = <5000000>;
26	};
27
28	reg_usbh_vbus: regulator-usbh-vbus {
29		compatible = "regulator-fixed";
30		pinctrl-names = "default";
31		pinctrl-0 = <&pinctrl_usbh_reg>;
32		regulator-name = "VCC_USB[1-4]";
33		regulator-min-microvolt = <5000000>;
34		regulator-max-microvolt = <5000000>;
35		gpio = <&gpio4 7 GPIO_ACTIVE_LOW>;
36		vin-supply = <&reg_5v0>;
37	};
38};
39
40&adc1 {
41	status = "okay";
42};
43
44&adc2 {
45	status = "okay";
46};
47
48/*
49 * The Atmel maxtouch controller uses SODIMM 28/30, also used for PWM<B>, PWM<C>, aka pwm2, pwm3.
50 * So if you enable following capacitive touch controller, disable pwm2/pwm3 first.
51 */
52&atmel_mxt_ts {
53	interrupt-parent = <&gpio1>;
54	interrupts = <9 IRQ_TYPE_EDGE_FALLING>;		/* SODIMM 28 / INT */
55	pinctrl-0 = <&pinctrl_atmel_adapter>;
56	reset-gpios = <&gpio1 10 GPIO_ACTIVE_LOW>;	/* SODIMM 30 / RST */
57	status = "disabled";
58};
59
60&ecspi3 {
61	status = "okay";
62
63	mcp2515: can@0 {
64		compatible = "microchip,mcp2515";
65		pinctrl-names = "default";
66		pinctrl-0 = <&pinctrl_can_int>;
67		reg = <0>;
68		clocks = <&clk16m>;
69		interrupt-parent = <&gpio5>;
70		interrupts = <2 IRQ_TYPE_EDGE_FALLING>;
71		spi-max-frequency = <10000000>;
72		vdd-supply = <&reg_3v3>;
73		xceiver-supply = <&reg_5v0>;
74		status = "okay";
75	};
76};
77
78&fec1 {
79	status = "okay";
80};
81
82&i2c4 {
83	status = "okay";
84
85	/* M41T0M6 real time clock on carrier board */
86	rtc: rtc@68 {
87		compatible = "st,m41t0";
88		reg = <0x68>;
89	};
90};
91
92&pwm1 {
93	status = "okay";
94};
95
96&pwm2 {
97	status = "okay";
98};
99
100&pwm3 {
101	status = "okay";
102};
103
104&pwm4 {
105	status = "okay";
106};
107
108&uart1 {
109	status = "okay";
110};
111
112&uart2 {
113	status = "okay";
114};
115
116&uart3 {
117	status = "okay";
118};
119
120&usbotg1 {
121	status = "okay";
122};
123
124&usdhc1 {
125	keep-power-in-suspend;
126	wakeup-source;
127	vmmc-supply = <&reg_3v3>;
128	status = "okay";
129};
130