imx219-overlay.dts 2.26 KB
Newer Older
notro's avatar
notro committed
1
2
3
4
5
6
7
8
9
10
11
// SPDX-License-Identifier: GPL-2.0-only
// Definitions for IMX219 camera module on VC I2C bus
/dts-v1/;
/plugin/;

#include <dt-bindings/gpio/gpio.h>

/{
	compatible = "brcm,bcm2835";

	fragment@0 {
12
		target = <&i2c_csi_dsi>;
notro's avatar
notro committed
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
		__overlay__ {
			#address-cells = <1>;
			#size-cells = <0>;
			status = "okay";

			imx219: imx219@10 {
				compatible = "sony,imx219";
				reg = <0x10>;
				status = "okay";

				clocks = <&imx219_clk>;
				clock-names = "xclk";

				VANA-supply = <&imx219_vana>;	/* 2.8v */
				VDIG-supply = <&imx219_vdig>;	/* 1.8v */
				VDDL-supply = <&imx219_vddl>;	/* 1.2v */

30
31
				rotation = <180>;

notro's avatar
notro committed
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
				port {
					imx219_0: endpoint {
						remote-endpoint = <&csi1_ep>;
						clock-lanes = <0>;
						data-lanes = <1 2>;
						clock-noncontinuous;
						link-frequencies =
							/bits/ 64 <297000000>;
					};
				};
			};
		};
	};

	fragment@1 {
		target = <&csi1>;
		__overlay__ {
			status = "okay";

			port {
				csi1_ep: endpoint {
					remote-endpoint = <&imx219_0>;
54
55
56
					clock-lanes = <0>;
					data-lanes = <1 2>;
					clock-noncontinuous;
notro's avatar
notro committed
57
58
59
60
61
62
				};
			};
		};
	};

	fragment@2 {
63
		target = <&i2c0if>;
notro's avatar
notro committed
64
65
66
67
68
		__overlay__ {
			status = "okay";
		};
	};

69
	fragment@3 {
notro's avatar
notro committed
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
		target-path="/";
		__overlay__ {
			imx219_vana: fixedregulator@0 {
				compatible = "regulator-fixed";
				regulator-name = "imx219_vana";
				regulator-min-microvolt = <2800000>;
				regulator-max-microvolt = <2800000>;
				gpio = <&gpio 41 GPIO_ACTIVE_HIGH>;
				enable-active-high;
			};
			imx219_vdig: fixedregulator@1 {
				compatible = "regulator-fixed";
				regulator-name = "imx219_vdig";
				regulator-min-microvolt = <1800000>;
				regulator-max-microvolt = <1800000>;
			};
			imx219_vddl: fixedregulator@2 {
				compatible = "regulator-fixed";
				regulator-name = "imx219_vddl";
				regulator-min-microvolt = <1200000>;
				regulator-max-microvolt = <1200000>;
			};
92
93
94
95
96
97

			imx219_clk: camera-clk {
				compatible = "fixed-clock";
				#clock-cells = <0>;
				clock-frequency = <24000000>;
			};
notro's avatar
notro committed
98
99
100
		};
	};

101
102
103
104
105
106
107
108
	fragment@4 {
		target = <&i2c0mux>;
		__overlay__ {
			status = "okay";
		};
	};

	fragment@5 {
notro's avatar
notro committed
109
110
111
112
113
114
		target-path="/__overrides__";
		__overlay__ {
			cam0-pwdn-ctrl = <&imx219_vana>,"gpio:0";
			cam0-pwdn      = <&imx219_vana>,"gpio:4";
		};
	};
115
116
117
118

	__overrides__ {
		rotation = <&imx219>,"rotation:0";
	};
notro's avatar
notro committed
119
};