xref: /OK3568_Linux_fs/kernel/arch/arm64/boot/dts/rockchip/rk3566-evb2-lp4x-v10-eink.dts (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
2/*
3 * Copyright (c) 2020 Rockchip Electronics Co., Ltd.
4 *
5 */
6
7#include "rk3566-evb2-lp4x-v10.dtsi"
8#include "rk3568-android.dtsi"
9#include "rk3566-eink.dtsi"
10
11/ {
12	model = "Rockchip RK3566 EVB2 LP4X V10 Eink Board";
13	compatible = "rockchip,rk3566-evb2-lp4x-v10-eink", "rockchip,rk3566";
14};
15
16&backlight {
17	status = "disabled";
18};
19
20&backlight1 {
21	status = "disabled";
22};
23
24&dsi0 {
25	status = "disabled";
26};
27
28&dsi0_in_vp0 {
29	status = "disabled";
30};
31
32&dsi0_panel {
33	status = "disabled";
34};
35
36&dsi1_panel {
37	status = "disabled";
38};
39
40&ebc {
41	/* clock rate 1000M/n, (n=1~32) */
42	assigned-clocks = <&cru CPLL_333M>, <&cru DCLK_EBC>;
43	//assigned-clock-rates = <340000000>, <340000000>;
44	assigned-clock-rates = <250000000>, <250000000>;
45	//assigned-clock-rates = <100000000>, <100000000>;
46	status = "okay";
47};
48
49&ebc_dev {
50	pmic = <&tps65185>;
51	status = "okay";
52#if 0
53	/* ED097TC2U1 */
54	panel,width = <1200>;
55	panel,height = <825>;
56	panel,vir_width = <1200>;
57	panel,vir_height = <825>;
58	panel,sdck = <25000000>;
59	panel,lsl = <4>;
60	panel,lbl = <4>;
61	panel,ldl = <300>;
62	panel,lel = <36>;
63	panel,gdck-sta = <18>;
64	panel,lgonl = <265>;
65	panel,fsl = <2>;
66	panel,fbl = <4>;
67	panel,fdl = <825>;
68	panel,fel = <24>;
69	panel,mirror = <0>;
70	panel,panel_16bit = <0>;
71	panel,panel_color = <0>;
72	panel,width-mm = <203>;
73	panel,height-mm = <140>;
74#endif
75#if 1
76	/* ES103TC1 */
77	panel,width = <1872>;
78	panel,height = <1404>;
79	panel,vir_width = <1872>;
80	panel,vir_height = <1404>;
81	panel,sdck = <33300000>;
82	panel,lsl = <18>;
83	panel,lbl = <17>;
84	panel,ldl = <234>;
85	panel,lel = <7>;
86	panel,gdck-sta = <34>;
87	panel,lgonl = <192>;
88	panel,fsl = <1>;
89	panel,fbl = <4>;
90	panel,fdl = <1404>;
91	panel,fel = <12>;
92	panel,mirror = <0>;
93	panel,panel_16bit = <1>;
94	panel,panel_color = <0>;
95	panel,width-mm = <157>;
96	panel,height-mm = <210>;
97#endif
98#if 0
99	/* ES133TC1 */
100	panel,width = <2200>;
101	panel,height = <1650>;
102	panel,vir_width = <2208>;
103	panel,vir_height = <1650>;
104	panel,sdck = <37500000>;
105	panel,lsl = <4>;
106	panel,lbl = <8>;
107	panel,ldl = <275>;
108	panel,lel = <14>;
109	panel,gdck-sta = <34>;
110	panel,lgonl = <217>;
111	panel,fsl = <1>;
112	panel,fbl = <4>;
113	panel,fdl = <1650>;
114	panel,fel = <6>;
115	panel,mirror = <0>;
116	panel,panel_16bit = <1>;
117	panel,panel_color = <0>;
118	panel,width-mm = <157>;
119	panel,height-mm = <210>;
120#endif
121#if 0
122	panel,width = <2232>;
123	panel,height = <1680>;
124	panel,vir_width = <2240>;
125	panel,vir_height = <1680>;
126	panel,sdck = <33300000>;
127	panel,lsl = <4>;
128	panel,lbl = <8>;
129	panel,ldl = <279>;
130	panel,lel = <14>;
131	panel,gdck-sta = <34>;
132	panel,lgonl = <217>;
133	panel,fsl = <1>;
134	panel,fbl = <4>;
135	panel,fdl = <1680>;
136	panel,fel = <6>;
137	panel,mirror = <0>;
138	panel,panel_16bit = <1>;
139	panel,panel_color = <0>;
140	panel,width-mm = <157>;
141	panel,height-mm = <210>;
142#endif
143};
144
145&gmac1 {
146	status = "disabled";
147};
148
149&gt1x {
150	status = "disabled";
151};
152
153&hdmi {
154	status = "disabled";
155};
156
157&hdmi_in_vp0 {
158	status = "disabled";
159};
160
161&hdmi_sound{
162	status = "disabled";
163};
164
165&i2c1 {
166	status = "okay";
167
168	tsc@24 {
169		status = "okay";
170		compatible = "cy,cyttsp5_i2c_adapter";
171		reg = <0x24>;
172		cy,adapter_id = "cyttsp5_i2c_adapter";
173		//cytp-supply = <&vcc_sd>;
174		cy,core {
175			cy,name = "cyttsp5_core";
176			pinctrl-names = "default";
177			pinctrl-0 = <&tsc_gpio>;
178			cy,irq_gpio =  <&gpio0 RK_PB5 GPIO_ACTIVE_HIGH>;
179			cy,rst_gpio =  <&gpio0 RK_PB6 GPIO_ACTIVE_HIGH>;
180			cy,hid_desc_register = <1>;
181			/* CY_CORE_FLAG_RESTORE_PARAMETERS */
182			cy,flags = <6>;
183			/* CY_CORE_EWG_NONE */
184			cy,easy_wakeup_gesture = <0>;
185			cy,btn_keys = <172 /* KEY_HOMEPAGE */
186						/* previously was KEY_HOME, new Android versions use KEY_HOMEPAGE */
187						139 /* KEY_MENU */
188						158 /* KEY_BACK */
189						217 /* KEY_SEARCH */
190						114 /* KEY_VOLUMEDOWN */
191						115 /* KEY_VOLUMEUP */
192						212 /* KEY_CAMERA */
193						116>; /* KEY_POWER */
194			cy,btn_keys-tag = <0>;
195			cy,mt {
196				cy,name = "cyttsp5_mt";
197				cy,inp_dev_name = "cyttsp5_mt";
198				cy,flags = <0>;
199				cy,abs =
200					/* ABS_MT_POSITION_X, CY_ABS_MIN_X, CY_ABS_MAX_X, 0, 0 */
201					<0x35 0 1872 0 0
202					/* ABS_MT_POSITION_Y, CY_ABS_MIN_Y, CY_ABS_MAX_Y, 0, 0 */
203					0x36 0 1404 0 0
204					/* ABS_MT_PRESSURE, CY_ABS_MIN_P, CY_ABS_MAX_P, 0, 0 */
205					0x3a 0 255 0 0
206					/* CY_IGNORE_VALUE, CY_ABS_MIN_W, CY_ABS_MAX_W, 0, 0 */
207					0xffff 0 255 0 0
208					/* ABS_MT_TRACKING_ID, CY_ABS_MIN_T, CY_ABS_MAX_T, 0, 0 */
209					0x39 0 15 0 0
210					/* ABS_MT_TOUCH_MAJOR, 0, 255, 0, 0 */
211					0x30 0 255 0 0
212					/* ABS_MT_TOUCH_MINOR, 0, 255, 0, 0 */
213					0x31 0 255 0 0
214					/* ABS_MT_ORIENTATION, -127, 127, 0, 0 */
215					0x34 0xffffff81 127 0 0
216					/* ABS_MT_TOOL_TYPE, 0, MT_TOOL_MAX, 0, 0 */
217					0x37 0 1 0 0
218					/* ABS_DISTANCE, 0, 255, 0, 0 */
219					0x19 0 255 0 0>;
220
221					cy,vkeys_x = <1872>;
222					cy,vkeys_y = <1404>;
223
224					cy,revert_x = <0>;
225					cy,revert_y = <0>;
226					cy,xy_exchange = <0>;
227
228					cy,virtual_keys = /* KeyCode CenterX CenterY Width Height */
229						/* KEY_BACK */
230						<158 1360 90 160 180
231						/* KEY_MENU */
232						139 1360 270 160 180
233						/* KEY_HOMEPAGE */
234						172 1360 450 160 180
235						/* KEY SEARCH */
236						217 1360 630 160 180>;
237			};
238
239			cy,btn {
240				cy,name = "cyttsp5_btn";
241				cy,inp_dev_name = "cyttsp5_btn";
242			};
243
244			cy,proximity {
245				cy,name = "cyttsp5_proximity";
246				cy,inp_dev_name = "cyttsp5_proximity";
247				cy,abs =
248					/* ABS_DISTANCE, CY_PROXIMITY_MIN_VAL, CY_PROXIMITY_MAX_VAL, 0, 0 */
249					<0x19 0 1 0 0>;
250			};
251		};
252	};
253
254	tps65185: tps65185@68 {
255		status = "okay";
256		compatible = "ti,tps65185";
257		reg = <0x68>;
258		pinctrl-names = "default";
259		pinctrl-0 = <&tps65185_gpio>;
260		int-gpios = <&gpio3 RK_PA7 GPIO_ACTIVE_HIGH>;
261		wakeup-gpios = <&gpio3 RK_PC3 GPIO_ACTIVE_HIGH>;
262		vcomctl-gpios = <&gpio4 RK_PB2 GPIO_ACTIVE_HIGH>;
263		powerup-gpios = <&gpio4 RK_PC5 GPIO_ACTIVE_HIGH>;
264	};
265};
266
267&i2c2 {
268	status = "disabled";
269};
270
271&i2c3 {
272	status = "okay";
273
274	wacom: wacom@9 {
275		compatible = "wacom,w9013";
276		reg = <0x09>;
277		pinctrl-names = "default";
278		pinctrl-0 = <&wacom_gpio>;
279		gpio_detect = <&gpio4 RK_PC4 GPIO_ACTIVE_HIGH>;
280		gpio_intr = <&gpio0 RK_PC1 GPIO_ACTIVE_HIGH>;
281		gpio_rst = <&gpio4 RK_PB1 GPIO_ACTIVE_HIGH>;
282		revert_x = <0>;
283		revert_y = <0>;
284		xy_exchange = <0>;
285	};
286};
287
288&video_phy0 {
289	status = "disabled";
290};
291
292&mxc6655xa {
293	status = "disabled";
294};
295
296&pinctrl {
297	tps_pmic {
298		tps65185_gpio: tps65185-gpio {
299				rockchip,pins =
300						<4 RK_PB2 RK_FUNC_GPIO &pcfg_pull_up>,
301						<4 RK_PC5 RK_FUNC_GPIO &pcfg_pull_up>,
302						<3 RK_PA7 RK_FUNC_GPIO &pcfg_pull_up>,
303						<3 RK_PC3 RK_FUNC_GPIO &pcfg_pull_up>;
304		};
305	};
306	tsc {
307		tsc_gpio: tsc-gpio {
308				rockchip,pins =
309						<0 RK_PB5 RK_FUNC_GPIO &pcfg_pull_up>,
310						<0 RK_PB6 RK_FUNC_GPIO &pcfg_pull_up>;
311		};
312	};
313	wacom {
314		wacom_gpio: wacom-gpio {
315				rockchip,pins =
316						<4 RK_PC4 RK_FUNC_GPIO &pcfg_pull_up>,
317						<0 RK_PC1 RK_FUNC_GPIO &pcfg_pull_up>,
318						<4 RK_PB1 RK_FUNC_GPIO &pcfg_pull_up>;
319		};
320	};
321};
322
323&pmu_io_domains {
324	status = "okay";
325	pmuio1-supply = <&vcc3v3_pmu>;
326	pmuio2-supply = <&vcc3v3_pmu>;
327	vccio1-supply = <&vccio_acodec>;
328	vccio3-supply = <&vccio_sd>;
329	vccio4-supply = <&vcc_1v8>;
330	vccio5-supply = <&vcc_3v3>;
331	vccio6-supply = <&vcc_3v3>;
332	vccio7-supply = <&vcc_3v3>;
333};
334
335&vcc_camera {
336	status = "disabled";
337};
338
339&wireless_bluetooth {
340	status = "disabled";
341};
342
343&wireless_wlan {
344	status = "disabled";
345};
346