hc
2024-09-20 a36159eec6ca17402b0e146b86efaf76568dc353
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
178
179
180
// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
// Copyright (C) 2019 Chen-Yu Tsai <wens@csie.org>
 
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
 
/ {
   aliases {
       serial0 = &uart0;
       spi0 = &spi0;
   };
 
   chosen {
       stdout-path = "serial0:115200n8";
   };
 
   connector {
       compatible = "hdmi-connector";
       type = "d";
 
       port {
           hdmi_con_in: endpoint {
               remote-endpoint = <&hdmi_out_con>;
           };
       };
   };
 
   leds {
       compatible = "gpio-leds";
 
       status_led {
           label = "librecomputer:blue:status";
           gpios = <&pio 0 7 GPIO_ACTIVE_HIGH>; /* PA7 */
       };
   };
 
   reg_vcc3v3: vcc3v3 {
       compatible = "regulator-fixed";
       regulator-name = "vcc3v3";
       regulator-min-microvolt = <3300000>;
       regulator-max-microvolt = <3300000>;
       regulator-always-on;
       regulator-boot-on;
       vin-supply = <&reg_vcc5v0>;
   };
 
   /* This represents the board's 5V input */
   reg_vcc5v0: vcc5v0 {
       compatible = "regulator-fixed";
       regulator-name = "vcc5v0";
       regulator-min-microvolt = <5000000>;
       regulator-max-microvolt = <5000000>;
       regulator-always-on;
       regulator-boot-on;
   };
 
   reg_vcc_dram: vcc-dram {
       compatible = "regulator-fixed";
       regulator-name = "vcc-dram";
       regulator-min-microvolt = <1500000>;
       regulator-max-microvolt = <1500000>;
       regulator-always-on;
       regulator-boot-on;
       vin-supply = <&reg_vcc5v0>;
       gpio = <&r_pio 0 9 GPIO_ACTIVE_HIGH>; /* PL9 */
       enable-active-high;
   };
 
   reg_vcc_io: vcc-io {
       compatible = "regulator-fixed";
       regulator-name = "vcc-io";
       /* This is simply a MOSFET switch */
       regulator-always-on;
       regulator-boot-on;
       vin-supply = <&reg_vcc3v3>;
       gpio = <&r_pio 0 5 GPIO_ACTIVE_LOW>; /* PL5 */
   };
 
   reg_vcc_usbwifi: vcc-usbwifi {
       compatible = "regulator-fixed";
       regulator-name = "vcc-usbwifi";
       regulator-min-microvolt = <3300000>;
       regulator-max-microvolt = <3300000>;
       vin-supply = <&reg_vcc5v0>;
       gpio = <&pio 6 4 GPIO_ACTIVE_HIGH>; /* PG4 */
       enable-active-high;
   };
 
   reg_vdd_cpux: vdd-cpux {
       compatible = "regulator-fixed";
       regulator-name = "vdd-cpux";
       regulator-min-microvolt = <1100000>;
       regulator-max-microvolt = <1100000>;
       regulator-always-on;
       regulator-boot-on;
       vin-supply = <&reg_vcc5v0>;
       gpio = <&r_pio 0 8 GPIO_ACTIVE_HIGH>; /* PL8 */
       enable-active-high;
   };
};
 
&cpu0 {
   cpu-supply = <&reg_vdd_cpux>;
};
 
&cpu1 {
   cpu-supply = <&reg_vdd_cpux>;
};
 
&cpu2 {
   cpu-supply = <&reg_vdd_cpux>;
};
 
&cpu3 {
   cpu-supply = <&reg_vdd_cpux>;
};
 
&de {
   status = "okay";
};
 
&ehci1 {
   status = "okay";
};
 
&hdmi {
   status = "okay";
};
 
&hdmi_out {
   hdmi_out_con: endpoint {
       remote-endpoint = <&hdmi_con_in>;
   };
};
 
&mmc0 {
   vmmc-supply = <&reg_vcc_io>;
   bus-width = <4>;
   cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>; /* PF6 */
   status = "okay";
};
 
&pio {
   vcc-pa-supply = <&reg_vcc_io>;
   vcc-pc-supply = <&reg_vcc_io>;
   vcc-pd-supply = <&reg_vcc_io>;
   vcc-pe-supply = <&reg_vcc_io>;
   vcc-pf-supply = <&reg_vcc_io>;
   vcc-pg-supply = <&reg_vcc_io>;
};
 
&r_pio {
   vcc-pl-supply = <&reg_vcc3v3>;
};
 
&spi0 {
   status = "okay";
 
   spiflash@0 {
       compatible = "jedec,spi-nor";
       reg = <0>;
       spi-max-frequency = <50000000>;
   };
};
 
&uart0 {
   pinctrl-names = "default";
   pinctrl-0 = <&uart0_pa_pins>;
   status = "okay";
};
 
&usb_otg {
   dr_mode = "peripheral";
   status = "okay";
};
 
&usbphy {
   usb1_vbus-supply = <&reg_vcc_usbwifi>;
   status = "okay";
};