1// SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2/*
3 * Device Tree Source for the White Hawk CSI/DSI sub-board
4 *
5 * Copyright (C) 2022 Glider bv
6 */
7
8#include <dt-bindings/media/video-interfaces.h>
9
10&csi40 {
11	status = "okay";
12
13	ports {
14		#address-cells = <1>;
15		#size-cells = <0>;
16
17		port@0 {
18			reg = <0>;
19
20			csi40_in: endpoint {
21				bus-type = <MEDIA_BUS_TYPE_CSI2_CPHY>;
22				clock-lanes = <0>;
23				data-lanes = <1 2 3>;
24				line-orders = <MEDIA_BUS_CSI2_CPHY_LINE_ORDER_ABC
25					       MEDIA_BUS_CSI2_CPHY_LINE_ORDER_BCA
26					       MEDIA_BUS_CSI2_CPHY_LINE_ORDER_ABC>;
27				remote-endpoint = <&max96712_out0>;
28			};
29		};
30	};
31};
32
33&csi41 {
34	status = "okay";
35
36	ports {
37		#address-cells = <1>;
38		#size-cells = <0>;
39
40		port@0 {
41			reg = <0>;
42
43			csi41_in: endpoint {
44				bus-type = <MEDIA_BUS_TYPE_CSI2_CPHY>;
45				clock-lanes = <0>;
46				data-lanes = <1 2 3>;
47				line-orders = <MEDIA_BUS_CSI2_CPHY_LINE_ORDER_ABC
48					       MEDIA_BUS_CSI2_CPHY_LINE_ORDER_BCA
49					       MEDIA_BUS_CSI2_CPHY_LINE_ORDER_ABC>;
50				remote-endpoint = <&max96712_out1>;
51			};
52		};
53	};
54};
55
56&i2c0 {
57	pca9654_a: gpio@21 {
58		compatible = "onnn,pca9654";
59		reg = <0x21>;
60		gpio-controller;
61		#gpio-cells = <2>;
62	};
63
64	pca9654_b: gpio@22 {
65		compatible = "onnn,pca9654";
66		reg = <0x22>;
67		gpio-controller;
68		#gpio-cells = <2>;
69	};
70
71	eeprom@52 {
72		compatible = "rohm,br24g01", "atmel,24c01";
73		label = "csi-dsi-sub-board-id";
74		reg = <0x52>;
75		pagesize = <8>;
76	};
77};
78
79&i2c1 {
80	gmsl0: gmsl-deserializer@49 {
81		compatible = "maxim,max96712";
82		reg = <0x49>;
83		enable-gpios = <&pca9654_a 0 GPIO_ACTIVE_HIGH>;
84
85		ports {
86			#address-cells = <1>;
87			#size-cells = <0>;
88
89			port@4 {
90				reg = <4>;
91				max96712_out0: endpoint {
92					bus-type = <MEDIA_BUS_TYPE_CSI2_CPHY>;
93					clock-lanes = <0>;
94					data-lanes = <1 2 3>;
95					remote-endpoint = <&csi40_in>;
96				};
97			};
98		};
99	};
100
101	gmsl1: gmsl-deserializer@4b {
102		compatible = "maxim,max96712";
103		reg = <0x4b>;
104		enable-gpios = <&pca9654_b 0 GPIO_ACTIVE_HIGH>;
105
106		ports {
107			#address-cells = <1>;
108			#size-cells = <0>;
109
110			port@4 {
111				reg = <4>;
112				max96712_out1: endpoint {
113					bus-type = <MEDIA_BUS_TYPE_CSI2_CPHY>;
114					clock-lanes = <0>;
115					data-lanes = <1 2 3>;
116					remote-endpoint = <&csi41_in>;
117				};
118			};
119		};
120	};
121};
122
123&isp0 {
124	status = "okay";
125};
126
127&isp1 {
128	status = "okay";
129};
130
131&vin00 {
132	status = "okay";
133};
134
135&vin01 {
136	status = "okay";
137};
138
139&vin02 {
140	status = "okay";
141};
142
143&vin03 {
144	status = "okay";
145};
146
147&vin04 {
148	status = "okay";
149};
150
151&vin05 {
152	status = "okay";
153};
154
155&vin06 {
156	status = "okay";
157};
158
159&vin07 {
160	status = "okay";
161};
162
163&vin08 {
164	status = "okay";
165};
166
167&vin09 {
168	status = "okay";
169};
170
171&vin10 {
172	status = "okay";
173};
174
175&vin11 {
176	status = "okay";
177};
178
179&vin12 {
180	status = "okay";
181};
182
183&vin13 {
184	status = "okay";
185};
186
187&vin14 {
188	status = "okay";
189};
190
191&vin15 {
192	status = "okay";
193};
194