1 From 870de3bc0e80a9b79b470a45636437a0078041c1 Mon Sep 17 00:00:00 2001
2 From: Dave Stevenson <dave.stevenson@raspberrypi.com>
3 Date: Tue, 7 Jul 2020 16:12:05 +0100
4 Subject: [PATCH] dtoverlays: Create an overlay for the Omnivision
7 Adds an overlay for the OV7251 VGA global shutter sensor.
9 Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
11 arch/arm/boot/dts/overlays/Makefile | 1 +
12 arch/arm/boot/dts/overlays/README | 8 ++
13 arch/arm/boot/dts/overlays/ov7251-overlay.dts | 111 ++++++++++++++++++
14 3 files changed, 120 insertions(+)
15 create mode 100644 arch/arm/boot/dts/overlays/ov7251-overlay.dts
17 --- a/arch/arm/boot/dts/overlays/Makefile
18 +++ b/arch/arm/boot/dts/overlays/Makefile
19 @@ -115,6 +115,7 @@ dtbo-$(CONFIG_ARCH_BCM2835) += \
27 --- a/arch/arm/boot/dts/overlays/README
28 +++ b/arch/arm/boot/dts/overlays/README
29 @@ -1813,6 +1813,14 @@ Load: dtoverlay=ov5647
34 +Info: Omnivision OV7251 camera module.
35 + Uses Unicam 1, which is the standard camera connector on most Pi
37 +Load: dtoverlay=ov7251
42 Info: Omnivision OV9281 camera module.
43 Uses Unicam 1, which is the standard camera connector on most Pi
45 +++ b/arch/arm/boot/dts/overlays/ov7251-overlay.dts
47 +// SPDX-License-Identifier: GPL-2.0-only
48 +// Definitions for OV7251 camera module on VC I2C bus
52 +#include <dt-bindings/gpio/gpio.h>
55 + compatible = "brcm,bcm2835";
58 + target = <&i2c_csi_dsi>;
60 + #address-cells = <1>;
65 + compatible = "ovti,ov7251";
69 + clocks = <&ov7251_clk>;
70 + clock-names = "xclk";
71 + clock-frequency = <24000000>;
73 + vdddo-supply = <&ov7251_dovdd>;
74 + vdda-supply = <&ov7251_avdd>;
75 + vddd-supply = <&ov7251_dvdd>;
77 + enable-gpios = <&gpio 41 GPIO_ACTIVE_HIGH>;
80 + ov7251_0: endpoint {
81 + remote-endpoint = <&csi1_ep>;
84 + clock-noncontinuous;
86 + /bits/ 64 <456000000>;
100 + remote-endpoint = <&ov7251_0>;
108 + target = <&i2c0if>;
117 + ov7251_avdd: fixedregulator@0 {
118 + compatible = "regulator-fixed";
119 + regulator-name = "ov7251_avdd";
120 + regulator-min-microvolt = <2800000>;
121 + regulator-max-microvolt = <2800000>;
123 + ov7251_dovdd: fixedregulator@1 {
124 + compatible = "regulator-fixed";
125 + regulator-name = "ov7251_dovdd";
126 + regulator-min-microvolt = <1800000>;
127 + regulator-max-microvolt = <1800000>;
129 + ov7251_dvdd: fixedregulator@2 {
130 + compatible = "regulator-fixed";
131 + regulator-name = "ov7251_dvdd";
132 + regulator-min-microvolt = <1200000>;
133 + regulator-max-microvolt = <1200000>;
135 + ov7251_clk: ov7251-clk {
136 + compatible = "fixed-clock";
137 + #clock-cells = <0>;
138 + clock-frequency = <24000000>;
144 + target = <&i2c0mux>;
151 + target-path="/__overrides__";
153 + cam0-pwdn-ctrl = <&ov7251>,"enable-gpios:0";
154 + cam0-pwdn = <&ov7251>,"enable-gpios:4";