Signed-off-by: hmz007 <hmz007@gmail.com>master
parent
7eddd1e8da
commit
6f8e28b178
@ -0,0 +1,152 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||||
/*
|
||||
* Copyright (c) 2022 FriendlyElec Computer Tech. Co., Ltd.
|
||||
* (http://www.friendlyelec.com)
|
||||
*
|
||||
* Copyright (c) 2022 Rockchip Electronics Co., Ltd.
|
||||
*/
|
||||
|
||||
&csi2_dcphy0 {
|
||||
status = "okay";
|
||||
|
||||
ports {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
port@0 {
|
||||
reg = <0>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
csidcphy0_in: endpoint@1 {
|
||||
reg = <1>;
|
||||
remote-endpoint = <&imx415_out1>;
|
||||
data-lanes = <1 2 3 4>;
|
||||
};
|
||||
};
|
||||
|
||||
port@1 {
|
||||
reg = <1>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
csidcphy0_out: endpoint@0 {
|
||||
reg = <0>;
|
||||
remote-endpoint = <&mipi0_csi2_input>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&i2c7 {
|
||||
status = "okay";
|
||||
|
||||
imx415p1: imx415@1a {
|
||||
compatible = "sony,imx415";
|
||||
reg = <0x1a>;
|
||||
clocks = <&cru CLK_MIPI_CAMARAOUT_M2>;
|
||||
clock-names = "xvclk";
|
||||
power-domains = <&power RK3588_PD_VI>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&mipim0_camera2_clk>;
|
||||
|
||||
power-gpios = <&gpio1 RK_PD3 GPIO_ACTIVE_HIGH>;
|
||||
reset-gpios = <&gpio1 RK_PD2 GPIO_ACTIVE_LOW>;
|
||||
rockchip,camera-module-index = <0>;
|
||||
rockchip,camera-module-facing = "back";
|
||||
rockchip,camera-module-name = "CMK-OT2022-PX1";
|
||||
rockchip,camera-module-lens-name = "IR0147-50IRC-8M-F20";
|
||||
|
||||
port {
|
||||
imx415_out1: endpoint {
|
||||
remote-endpoint = <&csidcphy0_in>;
|
||||
data-lanes = <1 2 3 4>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&mipi_dcphy0 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&mipi0_csi2 {
|
||||
status = "okay";
|
||||
|
||||
ports {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
port@0 {
|
||||
reg = <0>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
mipi0_csi2_input: endpoint@1 {
|
||||
reg = <1>;
|
||||
remote-endpoint = <&csidcphy0_out>;
|
||||
};
|
||||
};
|
||||
|
||||
port@1 {
|
||||
reg = <1>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
mipi0_csi2_output: endpoint@0 {
|
||||
reg = <0>;
|
||||
remote-endpoint = <&cif_mipi_in0>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&rkcif {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&rkcif_mipi_lvds {
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
cif_mipi_in0: endpoint {
|
||||
remote-endpoint = <&mipi0_csi2_output>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&rkcif_mipi_lvds_sditf {
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
mipi2_lvds_sditf: endpoint {
|
||||
remote-endpoint = <&isp0_vir0>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&rkcif_mmu {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&rkisp0 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&isp0_mmu {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&rkisp0_vir0 {
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
isp0_vir0: endpoint@0 {
|
||||
reg = <0>;
|
||||
remote-endpoint = <&mipi2_lvds_sditf>;
|
||||
};
|
||||
};
|
||||
};
|
@ -0,0 +1,75 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||||
/*
|
||||
* Copyright (c) 2024 FriendlyElec Computer Tech. Co., Ltd.
|
||||
* (http://www.friendlyelec.com)
|
||||
*/
|
||||
|
||||
#if (ENABLE_MIPI_DSI0)
|
||||
|
||||
&mipi_dcphy0 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&dsi0 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&dsi0_i2c {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
#if (HAS_PWM_BACKLIGHT)
|
||||
&dsi0_pwm {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&pwm_backlight {
|
||||
status = "okay";
|
||||
pwms = <&dsi0_pwm 0 25000 0>;
|
||||
};
|
||||
#endif
|
||||
|
||||
&dsi0_in_vp2 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&route_dsi0 {
|
||||
status = "okay";
|
||||
connect = <&vp2_out_dsi0>;
|
||||
};
|
||||
|
||||
#elif (ENABLE_MIPI_DSI1)
|
||||
|
||||
&mipi_dcphy1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&dsi1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&dsi1_i2c {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
#if (HAS_PWM_BACKLIGHT)
|
||||
&dsi1_pwm {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&pwm_backlight {
|
||||
status = "okay";
|
||||
pwms = <&dsi1_pwm 0 25000 0>;
|
||||
};
|
||||
#endif
|
||||
|
||||
&dsi1_in_vp2 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&route_dsi1 {
|
||||
status = "okay";
|
||||
connect = <&vp2_out_dsi1>;
|
||||
};
|
||||
|
||||
#endif
|
@ -0,0 +1,358 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||||
/*
|
||||
* Copyright (c) 2024 FriendlyElec Computer Tech. Co., Ltd.
|
||||
* (http://www.friendlyelec.com)
|
||||
*
|
||||
* Copyright (c) 2022 Rockchip Electronics Co., Ltd.
|
||||
*/
|
||||
|
||||
#define HAS_PWM_BACKLIGHT 1
|
||||
|
||||
&pwm_backlight {
|
||||
brightness-levels = <
|
||||
0 20 20 21 21 22 22 23
|
||||
23 24 24 25 25 26 26 27
|
||||
27 28 28 29 29 30 30 31
|
||||
31 32 32 33 33 34 34 35
|
||||
35 36 36 37 37 38 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 181 182 183
|
||||
184 185 186 187 188 189 190 191
|
||||
192 193 194 195 196 197 198 199
|
||||
200 201 202 203 204 205 206 207
|
||||
208 209 210 211 212 213 214 215
|
||||
216 217 218 219 220 221 222 223
|
||||
224 225 226 227 228 229 230 231
|
||||
232 233 234 235 236 237 238 239
|
||||
240 241 242 243 244 245 246 247
|
||||
248 249 250 251 252 253 254 255
|
||||
>;
|
||||
default-brightness-level = <200>;
|
||||
};
|
||||
|
||||
#if defined(ENABLE_MIPI_DSI0)
|
||||
&dsi0 {
|
||||
dsi0_panel: panel@0 {
|
||||
compatible = "simple-panel-dsi";
|
||||
reg = <0>;
|
||||
|
||||
backlight = <&pwm_backlight>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&lcd_rst0_gpio>;
|
||||
reset-gpios = <&gpio4 RK_PA3 GPIO_ACTIVE_LOW>;
|
||||
panel-name = "yx35,210dpi";
|
||||
nvmems = <&dsi0_i2c 0x50 0xe0 0x10>;
|
||||
nvmem-status = <1>;
|
||||
|
||||
reset-delay-ms = <20>;
|
||||
init-delay-ms = <120>;
|
||||
enable-delay-ms = <5>;
|
||||
prepare-delay-ms = <0>;
|
||||
unprepare-delay-ms = <10>;
|
||||
disable-delay-ms = <5>;
|
||||
width-mm = <45>;
|
||||
height-mm = <75>;
|
||||
|
||||
dsi,flags = <(MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_VIDEO_BURST |
|
||||
MIPI_DSI_MODE_LPM | MIPI_DSI_CLOCK_NON_CONTINUOUS)>;
|
||||
dsi,format = <MIPI_DSI_FMT_RGB888>;
|
||||
dsi,lanes = <2>;
|
||||
panel-init-sequence = [
|
||||
15 0A 02 01 00
|
||||
15 7D 02 11 00
|
||||
39 00 06 FF 77 01 00 00 13
|
||||
15 00 02 EF 08
|
||||
39 00 06 FF 77 01 00 00 10
|
||||
39 00 03 C0 63 00
|
||||
39 00 03 C1 14 14
|
||||
39 00 03 C2 37 02
|
||||
15 00 02 CC 10
|
||||
39 00 11 B0 C5 11 1B 0D 11 07 0A 09 08 24 05 12 10 A9 32 DF
|
||||
39 00 11 B1 C5 19 21 0B 0E 03 0C 07 07 26 04 12 11 AA 32 DF
|
||||
39 00 06 FF 77 01 00 00 11
|
||||
15 00 02 B0 4D
|
||||
15 00 02 B1 59
|
||||
15 00 02 B2 81
|
||||
15 00 02 B3 80
|
||||
15 00 02 B5 4E
|
||||
15 00 02 B7 85
|
||||
15 00 02 B8 32
|
||||
15 00 02 BB 03
|
||||
15 00 02 C1 08
|
||||
15 00 02 C2 08
|
||||
15 00 02 D0 88
|
||||
39 00 04 E0 00 00 02
|
||||
39 00 0C E1 06 28 08 28 05 28 07 28 0E 33 33
|
||||
39 00 0D E2 30 30 33 33 34 00 00 00 34 00 00 00
|
||||
39 00 05 E3 00 00 33 33
|
||||
39 00 03 E4 44 44
|
||||
39 00 11 E5 09 2F 2C 8C 0B 31 2C 8C 0D 33 2C 8C 0F 35 2C 8C
|
||||
39 00 05 E6 00 00 33 33
|
||||
39 00 03 E7 44 44
|
||||
39 00 11 E8 08 2E 2C 8C 0A 30 2C 8C 0C 32 2C 8C 0E 34 2C 8C
|
||||
39 00 03 E9 36 00
|
||||
39 00 08 EB 00 01 E4 E4 44 88 40
|
||||
39 00 11 ED FF FC B2 45 67 FA 01 FF FF 10 AF 76 54 2B CF FF
|
||||
39 00 07 EF 08 08 08 45 3F 54
|
||||
39 00 06 FF 77 01 00 00 13
|
||||
39 00 03 E8 00 0E
|
||||
15 78 02 11 00
|
||||
39 0A 03 E8 00 0C
|
||||
39 00 03 E8 00 00
|
||||
39 00 06 FF 77 01 00 00 00
|
||||
15 00 02 36 00
|
||||
15 00 02 29 00
|
||||
];
|
||||
|
||||
panel-exit-sequence = [
|
||||
15 00 02 28 00
|
||||
15 3C 02 10 00
|
||||
];
|
||||
|
||||
disp_timings0: display-timings {
|
||||
native-mode = <&dsi_timing0>;
|
||||
dsi_timing0: timing0 {
|
||||
clock-frequency = <29700000>;
|
||||
hactive = <480>;
|
||||
vactive = <800>;
|
||||
hfront-porch = <40>;
|
||||
hsync-len = <32>;
|
||||
hback-porch = <30>;
|
||||
vfront-porch = <20>;
|
||||
vsync-len = <10>;
|
||||
vback-porch = <20>;
|
||||
hsync-active = <0>;
|
||||
vsync-active = <0>;
|
||||
de-active = <0>;
|
||||
pixelclk-active = <0>;
|
||||
};
|
||||
};
|
||||
|
||||
ports {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
port@0 {
|
||||
reg = <0>;
|
||||
panel_in_dsi0: endpoint {
|
||||
remote-endpoint = <&dsi0_out_panel>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
ports {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
port@1 {
|
||||
reg = <1>;
|
||||
dsi0_out_panel: endpoint {
|
||||
remote-endpoint = <&panel_in_dsi0>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&dsi0_i2c {
|
||||
dsi0_gt1x: gt1x@14 {
|
||||
compatible = "goodix,gt1x";
|
||||
reg = <0x14>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&touch_dsi0_gpio>;
|
||||
goodix,irq-gpio = <&gpio3 RK_PC0 IRQ_TYPE_LEVEL_LOW>;
|
||||
goodix,rst-gpio = <&gpio3 RK_PC1 GPIO_ACTIVE_HIGH>;
|
||||
keep-otp-config;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
dsi0_gt9xx: gt9xx@5d {
|
||||
compatible = "goodix,gt9xx";
|
||||
reg = <0x5d>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&touch_dsi0_gpio>;
|
||||
interrupt-parent = <&gpio3>;
|
||||
interrupts = <RK_PC0 IRQ_TYPE_EDGE_FALLING>;
|
||||
goodix,irq-gpio = <&gpio3 RK_PC0 IRQ_TYPE_LEVEL_LOW>;
|
||||
goodix,rst-gpio = <&gpio3 RK_PC1 GPIO_ACTIVE_HIGH>;
|
||||
keep-otp-config;
|
||||
status = "disabled";
|
||||
};
|
||||
};
|
||||
#endif
|
||||
|
||||
#if defined(ENABLE_MIPI_DSI1)
|
||||
&dsi1 {
|
||||
dsi1_panel: panel@0 {
|
||||
compatible = "simple-panel-dsi";
|
||||
reg = <0>;
|
||||
|
||||
backlight = <&pwm_backlight>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&lcd_rst1_gpio>;
|
||||
reset-gpios = <&gpio4 RK_PA1 GPIO_ACTIVE_LOW>;
|
||||
panel-name = "yx35,210dpi";
|
||||
nvmems = <&dsi1_i2c 0x50 0xe0 0x10>;
|
||||
nvmem-status = <1>;
|
||||
|
||||
reset-delay-ms = <20>;
|
||||
init-delay-ms = <120>;
|
||||
enable-delay-ms = <5>;
|
||||
prepare-delay-ms = <0>;
|
||||
unprepare-delay-ms = <10>;
|
||||
disable-delay-ms = <5>;
|
||||
width-mm = <45>;
|
||||
height-mm = <75>;
|
||||
|
||||
dsi,flags = <(MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_VIDEO_BURST |
|
||||
MIPI_DSI_MODE_LPM | MIPI_DSI_CLOCK_NON_CONTINUOUS)>;
|
||||
dsi,format = <MIPI_DSI_FMT_RGB888>;
|
||||
dsi,lanes = <2>;
|
||||
panel-init-sequence = [
|
||||
15 0A 02 01 00
|
||||
15 7D 02 11 00
|
||||
39 00 06 FF 77 01 00 00 13
|
||||
15 00 02 EF 08
|
||||
39 00 06 FF 77 01 00 00 10
|
||||
39 00 03 C0 63 00
|
||||
39 00 03 C1 14 14
|
||||
39 00 03 C2 37 02
|
||||
15 00 02 CC 10
|
||||
39 00 11 B0 C5 11 1B 0D 11 07 0A 09 08 24 05 12 10 A9 32 DF
|
||||
39 00 11 B1 C5 19 21 0B 0E 03 0C 07 07 26 04 12 11 AA 32 DF
|
||||
39 00 06 FF 77 01 00 00 11
|
||||
15 00 02 B0 4D
|
||||
15 00 02 B1 59
|
||||
15 00 02 B2 81
|
||||
15 00 02 B3 80
|
||||
15 00 02 B5 4E
|
||||
15 00 02 B7 85
|
||||
15 00 02 B8 32
|
||||
15 00 02 BB 03
|
||||
15 00 02 C1 08
|
||||
15 00 02 C2 08
|
||||
15 00 02 D0 88
|
||||
39 00 04 E0 00 00 02
|
||||
39 00 0C E1 06 28 08 28 05 28 07 28 0E 33 33
|
||||
39 00 0D E2 30 30 33 33 34 00 00 00 34 00 00 00
|
||||
39 00 05 E3 00 00 33 33
|
||||
39 00 03 E4 44 44
|
||||
39 00 11 E5 09 2F 2C 8C 0B 31 2C 8C 0D 33 2C 8C 0F 35 2C 8C
|
||||
39 00 05 E6 00 00 33 33
|
||||
39 00 03 E7 44 44
|
||||
39 00 11 E8 08 2E 2C 8C 0A 30 2C 8C 0C 32 2C 8C 0E 34 2C 8C
|
||||
39 00 03 E9 36 00
|
||||
39 00 08 EB 00 01 E4 E4 44 88 40
|
||||
39 00 11 ED FF FC B2 45 67 FA 01 FF FF 10 AF 76 54 2B CF FF
|
||||
39 00 07 EF 08 08 08 45 3F 54
|
||||
39 00 06 FF 77 01 00 00 13
|
||||
39 00 03 E8 00 0E
|
||||
15 78 02 11 00
|
||||
39 0A 03 E8 00 0C
|
||||
39 00 03 E8 00 00
|
||||
39 00 06 FF 77 01 00 00 00
|
||||
15 00 02 36 00
|
||||
15 00 02 29 00
|
||||
];
|
||||
|
||||
panel-exit-sequence = [
|
||||
15 00 02 28 00
|
||||
15 3C 02 10 00
|
||||
];
|
||||
|
||||
display-timings {
|
||||
native-mode = <&dsi1_timing0>;
|
||||
dsi1_timing0: timing0 {
|
||||
clock-frequency = <29700000>;
|
||||
hactive = <480>;
|
||||
vactive = <800>;
|
||||
hfront-porch = <40>;
|
||||
hsync-len = <32>;
|
||||
hback-porch = <30>;
|
||||
vfront-porch = <20>;
|
||||
vsync-len = <10>;
|
||||
vback-porch = <20>;
|
||||
hsync-active = <0>;
|
||||
vsync-active = <0>;
|
||||
de-active = <0>;
|
||||
pixelclk-active = <0>;
|
||||
};
|
||||
};
|
||||
|
||||
ports {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
port@0 {
|
||||
reg = <0>;
|
||||
panel_in_dsi1: endpoint {
|
||||
remote-endpoint = <&dsi1_out_panel>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
ports {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
port@1 {
|
||||
reg = <1>;
|
||||
dsi1_out_panel: endpoint {
|
||||
remote-endpoint = <&panel_in_dsi1>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&dsi1_i2c {
|
||||
dsi1_gt1x: gt1x@14 {
|
||||
compatible = "goodix,gt1x";
|
||||
reg = <0x14>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&touch_dsi1_gpio>;
|
||||
goodix,irq-gpio = <&gpio4 RK_PA0 IRQ_TYPE_EDGE_FALLING>;
|
||||
goodix,rst-gpio = <&gpio4 RK_PA1 GPIO_ACTIVE_HIGH>;
|
||||
keep-otp-config;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
dsi1_gt9xx: gt9xx@5d {
|
||||
compatible = "goodix,gt9xx";
|
||||
reg = <0x5d>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&touch_dsi1_gpio>;
|
||||
interrupt-parent = <&gpio4>;
|
||||
interrupts = <RK_PA0 IRQ_TYPE_EDGE_FALLING>;
|
||||
goodix,irq-gpio = <&gpio4 RK_PA0 IRQ_TYPE_EDGE_FALLING>;
|
||||
goodix,rst-gpio = <&gpio4 RK_PA1 GPIO_ACTIVE_HIGH>;
|
||||
keep-otp-config;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
dsi1_e2prom: eeprom@50 {
|
||||
compatible = "microchip,24c02", "atmel,24c02";
|
||||
reg = <0x50>;
|
||||
#address-cells = <2>;
|
||||
#size-cells = <0>;
|
||||
pagesize = <16>;
|
||||
size = <256>;
|
||||
};
|
||||
};
|
||||
#endif
|
@ -0,0 +1,462 @@
|
||||
// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||||
/*
|
||||
* Copyright (c) 2024 FriendlyElec Computer Tech. Co., Ltd.
|
||||
* (http://www.friendlyelec.com)
|
||||
*
|
||||
* Copyright (c) 2021 Rockchip Electronics Co., Ltd.
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
|
||||
#include "rk3588-nanopi6-common.dtsi"
|
||||
|
||||
/ {
|
||||
model = "FriendlyElec NanoPi M6";
|
||||
compatible = "friendlyelec,nanopi-m6", "rockchip,rk3588";
|
||||
|
||||
aliases {
|
||||
ethernet0 = &gmac1;
|
||||
};
|
||||
|
||||
rt5616_sound: rt5616-sound {
|
||||
status = "okay";
|
||||
compatible = "simple-audio-card";
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&hp_det>;
|
||||
|
||||
simple-audio-card,name = "realtek,rt5616-codec";
|
||||
simple-audio-card,format = "i2s";
|
||||
simple-audio-card,mclk-fs = <256>;
|
||||
|
||||
simple-audio-card,hp-det-gpio = <&gpio1 RK_PC4 GPIO_ACTIVE_LOW>;
|
||||
simple-audio-card,hp-pin-name = "Headphone Jack";
|
||||
|
||||
simple-audio-card,widgets =
|
||||
"Headphone", "Headphone Jack",
|
||||
"Microphone", "Microphone Jack";
|
||||
simple-audio-card,routing =
|
||||
"Headphone Jack", "HPOL",
|
||||
"Headphone Jack", "HPOR",
|
||||
"MIC1", "Microphone Jack",
|
||||
"Microphone Jack", "micbias1";
|
||||
|
||||
simple-audio-card,cpu {
|
||||
sound-dai = <&i2s0_8ch>;
|
||||
};
|
||||
simple-audio-card,codec {
|
||||
sound-dai = <&rt5616>;
|
||||
};
|
||||
};
|
||||
|
||||
fan: pwm-fan {
|
||||
status = "okay";
|
||||
compatible = "pwm-fan";
|
||||
#cooling-cells = <2>;
|
||||
fan-supply = <&vcc5v0_sys>;
|
||||
pwms = <&pwm5 0 50000 0>;
|
||||
cooling-levels = <0 45 70 110 160 255>;
|
||||
rockchip,hold-time-ms = <2000>;
|
||||
rockchip,temp-trips = <
|
||||
50000 1
|
||||
55000 2
|
||||
60000 3
|
||||
65000 4
|
||||
70000 5
|
||||
>;
|
||||
};
|
||||
|
||||
adc_keys: adc-keys {
|
||||
compatible = "adc-keys";
|
||||
io-channels = <&saradc 1>;
|
||||
io-channel-names = "buttons";
|
||||
keyup-threshold-microvolt = <1800000>;
|
||||
poll-interval = <100>;
|
||||
|
||||
vol-up-key {
|
||||
label = "volume up";
|
||||
linux,code = <KEY_VOLUMEUP>;
|
||||
press-threshold-microvolt = <17000>;
|
||||
};
|
||||
};
|
||||
|
||||
gpio_leds: gpio-leds {
|
||||
compatible = "gpio-leds";
|
||||
|
||||
sys_led: led-0 {
|
||||
gpios = <&gpio1 RK_PA4 GPIO_ACTIVE_HIGH>;
|
||||
label = "sys_led";
|
||||
linux,default-trigger = "heartbeat";
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&sys_led_pin>;
|
||||
};
|
||||
|
||||
user_led: led-1 {
|
||||
gpios = <&gpio1 RK_PA6 GPIO_ACTIVE_HIGH>;
|
||||
label = "user_led";
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&user_led_pin>;
|
||||
};
|
||||
};
|
||||
|
||||
vcc3v3_pcie_m2: vcc3v3-pcie30 {
|
||||
compatible = "regulator-fixed";
|
||||
enable-active-high;
|
||||
gpios = <&gpio3 RK_PC6 GPIO_ACTIVE_HIGH>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pcie_m2_0_pwren>;
|
||||
regulator-name = "vcc3v3_pcie_m2";
|
||||
regulator-min-microvolt = <3300000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
vin-supply = <&vcc5v0_sys>;
|
||||
};
|
||||
|
||||
vcc5v0_host_20: vcc5v0-host-20 {
|
||||
compatible = "regulator-fixed";
|
||||
enable-active-high;
|
||||
gpio = <&gpio4 RK_PB5 GPIO_ACTIVE_HIGH>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&vcc5v0_host20_en>;
|
||||
regulator-name = "vcc5v0_host_20";
|
||||
regulator-min-microvolt = <5000000>;
|
||||
regulator-max-microvolt = <5000000>;
|
||||
vin-supply = <&vcc5v0_usb>;
|
||||
};
|
||||
|
||||
vbus5v0_typec: vbus5v0-typec {
|
||||
compatible = "regulator-fixed";
|
||||
enable-active-high;
|
||||
gpio = <&gpio3 RK_PD4 GPIO_ACTIVE_HIGH>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&typec5v_pwren>;
|
||||
regulator-name = "vbus5v0_typec";
|
||||
regulator-min-microvolt = <5000000>;
|
||||
regulator-max-microvolt = <5000000>;
|
||||
vin-supply = <&vcc5v0_usb>;
|
||||
};
|
||||
};
|
||||
|
||||
&mach {
|
||||
hwrev = <0x0a>;
|
||||
model = "NanoPi M6";
|
||||
};
|
||||
|
||||
&pcie2x1l1 {
|
||||
rockchip,skip-hw-retry;
|
||||
};
|
||||
|
||||
&pcie2x1l2 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pcie_m2_0_prsnt>;
|
||||
prsnt-gpios = <&gpio4 RK_PA5 GPIO_ACTIVE_HIGH>;
|
||||
phys = <&combphy0_ps PHY_TYPE_PCIE 0>;
|
||||
rockchip,skip-hw-retry;
|
||||
vpcie3v3-supply = <&vcc3v3_pcie_m2>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&combphy0_ps {
|
||||
#phy-cells = <2>;
|
||||
rockchip,ebuff-mode;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&sata0 {
|
||||
phys = <&combphy0_ps PHY_TYPE_SATA 1>;
|
||||
target-supply = <&vcc3v3_pcie_m2>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&pinctrl {
|
||||
gpio-leds {
|
||||
sys_led_pin: sys-led-pin {
|
||||
rockchip,pins =
|
||||
<1 RK_PA4 RK_FUNC_GPIO &pcfg_pull_none>;
|
||||
};
|
||||
|
||||
user_led_pin: lan1-led-pin {
|
||||
rockchip,pins =
|
||||
<1 RK_PA6 RK_FUNC_GPIO &pcfg_pull_none>;
|
||||
};
|
||||
};
|
||||
|
||||
headphone {
|
||||
hp_det: hp-det {
|
||||
rockchip,pins = <1 RK_PC4 RK_FUNC_GPIO &pcfg_pull_none>;
|
||||
};
|
||||
};
|
||||
|
||||
lcd {
|
||||
/omit-if-no-ref/
|
||||
lcd_rst0_gpio: lcd-rst0-gpio {
|
||||
rockchip,pins = <3 RK_PD2 RK_FUNC_GPIO &pcfg_pull_none>;
|
||||
};
|
||||
|
||||
/omit-if-no-ref/
|
||||
lcd_rst1_gpio: lcd-rst1-gpio {
|
||||
rockchip,pins = <4 RK_PA1 RK_FUNC_GPIO &pcfg_pull_none>;
|
||||
};
|
||||
|
||||
/omit-if-no-ref/
|
||||
touch_dsi0_gpio: touch-dsi0-gpio {
|
||||
rockchip,pins =
|
||||
<3 RK_PC0 RK_FUNC_GPIO &pcfg_pull_up>,
|
||||
<3 RK_PC1 RK_FUNC_GPIO &pcfg_pull_none>;
|
||||
};
|
||||
|
||||
/omit-if-no-ref/
|
||||
touch_dsi1_gpio: touch-dsi1-gpio {
|
||||
rockchip,pins =
|
||||
<4 RK_PA0 RK_FUNC_GPIO &pcfg_pull_up>,
|
||||
<4 RK_PA2 RK_FUNC_GPIO &pcfg_pull_none>;
|
||||
};
|
||||
};
|
||||
|
||||
pcie {
|
||||
pcie_m2_0_pwren: pcie-m20-pwren {
|
||||
rockchip,pins = <3 RK_PC6 RK_FUNC_GPIO &pcfg_pull_none>;
|
||||
};
|
||||
pcie_m2_0_prsnt: pcie-m20-prsnt {
|
||||
rockchip,pins = <4 RK_PA5 RK_FUNC_GPIO &pcfg_pull_up>;
|
||||
};
|
||||
};
|
||||
|
||||
usb {
|
||||
typec5v_pwren: typec5v-pwren {
|
||||
rockchip,pins = <3 RK_PD4 RK_FUNC_GPIO &pcfg_pull_none>;
|
||||
};
|
||||
|
||||
vcc5v0_host20_en: vcc5v0-host20-en {
|
||||
rockchip,pins = <4 RK_PB5 RK_FUNC_GPIO &pcfg_pull_none>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
dsi0_i2c: &i2c4 {
|
||||
clock-frequency = <200000>;
|
||||
pinctrl-0 = <&i2c4m3_xfer>;
|
||||
};
|
||||
|
||||
dsi1_i2c: &i2c5 {
|
||||
clock-frequency = <200000>;
|
||||
pinctrl-0 = <&i2c5m2_xfer>;
|
||||
};
|
||||
|
||||
&i2c6 {
|
||||
clock-frequency = <200000>;
|
||||
status = "okay";
|
||||
|
||||
eeprom@53 {
|
||||
compatible = "microchip,24c02", "atmel,24c02";
|
||||
reg = <0x53>;
|
||||
#address-cells = <2>;
|
||||
#size-cells = <0>;
|
||||
pagesize = <16>;
|
||||
size = <256>;
|
||||
|
||||
eui_48: eui-48@fa {
|
||||
reg = <0xfa 0x06>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&i2c7 {
|
||||
clock-frequency = <200000>;
|
||||
status = "okay";
|
||||
|
||||
rt5616: rt5616@1b {
|
||||
status = "okay";
|
||||
#sound-dai-cells = <0>;
|
||||
compatible = "rt5616";
|
||||
reg = <0x1b>;
|
||||
clocks = <&mclkout_i2s0>;
|
||||
clock-names = "mclk";
|
||||
assigned-clocks = <&mclkout_i2s0>;
|
||||
assigned-clock-rates = <12288000>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&i2s0_mclk>;
|
||||
};
|
||||
|
||||
/* connected with MIPI-CSI1 */
|
||||
};
|
||||
|
||||
&i2s0_8ch {
|
||||
status = "okay";
|
||||
pinctrl-0 = <&i2s0_lrck
|
||||
&i2s0_sclk
|
||||
&i2s0_sdi0
|
||||
&i2s0_sdo0>;
|
||||
rockchip,trcm-sync-tx-only;
|
||||
};
|
||||
|
||||
&pwm5 {
|
||||
pinctrl-0 = <&pwm5m1_pins>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
dsi0_pwm: &pwm10 {
|
||||
pinctrl-0 = <&pwm10m2_pins>;
|
||||
};
|
||||
|
||||
dsi1_pwm: &pwm11 {
|
||||
pinctrl-0 = <&pwm11m3_pins>;
|
||||
};
|
||||
|
||||
&u2phy0 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&u2phy0_otg {
|
||||
phy-supply = <&vbus5v0_typec>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&u2phy2 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&u2phy2_host {
|
||||
phy-supply = <&vcc5v0_host_20>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&u2phy3 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&u2phy3_host {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usb_host1_ehci {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usb_host1_ohci {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
/* MIPI-CSI */
|
||||
#define ENABLE_MIPI_DCSI0 0
|
||||
|
||||
#if (ENABLE_MIPI_CSI0)
|
||||
#include "rk3588-nanopi6-csi0-imx415.dtsi"
|
||||
|
||||
&imx415p0 {
|
||||
power-gpios = <&gpio1 RK_PD5 GPIO_ACTIVE_HIGH>;
|
||||
reset-gpios = <&gpio1 RK_PC6 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
#endif
|
||||
|
||||
#if (ENABLE_MIPI_DCSI0)
|
||||
#include "rk3588-nanopi6-dcsi0-imx415.dtsi"
|
||||
#endif
|
||||
|
||||
/* MIPI-DSI */
|
||||
#define ENABLE_MIPI_DSI1 1
|
||||
|
||||
#include "rk3588-nanopi6-mipi-lcd-yx35.dtsi"
|
||||
#include "rk3588-nanopi6-mipi-dsi-sel.dtsi"
|
||||
|
||||
#if defined(ENABLE_MIPI_DSI0)
|
||||
&dsi0_panel {
|
||||
reset-gpios = <&gpio3 RK_PD2 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
&dsi0_gt1x {
|
||||
compatible = "goodix,gt1x", "goodix,gt9xx";
|
||||
interrupt-parent = <&gpio3>;
|
||||
interrupts = <RK_PC0 IRQ_TYPE_EDGE_FALLING>;
|
||||
goodix,irq-gpio = <&gpio3 RK_PC0 IRQ_TYPE_EDGE_FALLING>;
|
||||
goodix,rst-gpio = <&gpio3 RK_PC1 GPIO_ACTIVE_HIGH>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&dsi0_gt9xx {
|
||||
interrupt-parent = <&gpio3>;
|
||||
interrupts = <RK_PC0 IRQ_TYPE_EDGE_FALLING>;
|
||||
goodix,irq-gpio = <&gpio3 RK_PC0 IRQ_TYPE_EDGE_FALLING>;
|
||||
goodix,rst-gpio = <&gpio3 RK_PC1 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
#endif
|
||||
|
||||
#if defined(ENABLE_MIPI_DSI1)
|
||||
&dsi1_panel {
|
||||
reset-gpios = <&gpio4 RK_PA1 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
&dsi1_gt1x {
|
||||
compatible = "goodix,gt1x", "goodix,gt9xx";
|
||||
interrupt-parent = <&gpio4>;
|
||||
interrupts = <RK_PA0 IRQ_TYPE_EDGE_FALLING>;
|
||||
goodix,irq-gpio = <&gpio4 RK_PA0 IRQ_TYPE_EDGE_FALLING>;
|
||||
goodix,rst-gpio = <&gpio4 RK_PA2 GPIO_ACTIVE_HIGH>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&dsi1_gt9xx {
|
||||
interrupt-parent = <&gpio4>;
|
||||
interrupts = <RK_PA0 IRQ_TYPE_EDGE_FALLING>;
|
||||
goodix,irq-gpio = <&gpio4 RK_PA0 IRQ_TYPE_EDGE_FALLING>;
|
||||
goodix,rst-gpio = <&gpio4 RK_PA2 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
#endif
|
||||
|
||||
#undef ENABLE_MIPI_DSI1
|
||||
|
||||
/* GPIO Connector */
|
||||
&i2c1 {
|
||||
pinctrl-0 = <&i2c1m2_xfer>;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&i2c8 {
|
||||
pinctrl-0 = <&i2c8m2_xfer>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&spi0 {
|
||||
pinctrl-0 = <&spi0m2_cs0 &spi0m2_pins>;
|
||||
status = "disabled";
|
||||
|
||||
spidev0: spidev@0 {
|
||||
compatible = "rockchip,spidev";
|
||||
reg = <0>;
|
||||
spi-max-frequency = <10000000>;
|
||||
status = "disabled";
|
||||
};
|
||||
};
|
||||
|
||||
&uart0 {
|
||||
pinctrl-0 = <&uart0m0_xfer>;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&uart4 {
|
||||
pinctrl-0 = <&uart4m2_xfer>;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&uart5 {
|
||||
pinctrl-0 = <&uart5m1_xfer>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&uart6 {
|
||||
pinctrl-0 = <&uart6m1_xfer>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&uart7 {
|
||||
pinctrl-0 = <&uart7m2_xfer>;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&uart8 {
|
||||
pinctrl-0 = <&uart8m0_xfer>;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&pwm2 {
|
||||
pinctrl-0 = <&pwm2m0_pins>;
|
||||
status = "okay";
|
||||
};
|
Loading…
Reference in new issue