1 From 489b7fc3df2013766f3c4d5f682dcc7992950293 Mon Sep 17 00:00:00 2001
2 From: Dave Stevenson <dave.stevenson@raspberrypi.com>
3 Date: Mon, 6 Jul 2020 17:32:21 +0100
4 Subject: [PATCH] dtoverlay: Add overlay for Omnivision OV9281 image
7 Adds an overlay for the OV9281 mono imaging sensor using 2 CSI-2
10 Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
12 arch/arm/boot/dts/overlays/Makefile | 1 +
13 arch/arm/boot/dts/overlays/README | 8 ++
14 arch/arm/boot/dts/overlays/ov9281-overlay.dts | 110 ++++++++++++++++++
15 3 files changed, 119 insertions(+)
16 create mode 100644 arch/arm/boot/dts/overlays/ov9281-overlay.dts
18 --- a/arch/arm/boot/dts/overlays/Makefile
19 +++ b/arch/arm/boot/dts/overlays/Makefile
20 @@ -115,6 +115,7 @@ dtbo-$(CONFIG_ARCH_BCM2835) += \
28 --- a/arch/arm/boot/dts/overlays/README
29 +++ b/arch/arm/boot/dts/overlays/README
30 @@ -1813,6 +1813,14 @@ Load: dtoverlay=ov5647
35 +Info: Omnivision OV9281 camera module.
36 + Uses Unicam 1, which is the standard camera connector on most Pi
38 +Load: dtoverlay=ov9281
43 Info: PaPiRus ePaper Screen by Pi Supply (both HAT and pHAT)
44 Load: dtoverlay=papirus,<param>=<val>
46 +++ b/arch/arm/boot/dts/overlays/ov9281-overlay.dts
48 +// SPDX-License-Identifier: GPL-2.0-only
49 +// Definitions for OV9281 camera module on VC I2C bus
53 +#include <dt-bindings/gpio/gpio.h>
56 + compatible = "brcm,bcm2835";
59 + target = <&i2c_csi_dsi>;
61 + #address-cells = <1>;
66 + compatible = "ovti,ov9281";
70 + clocks = <&ov9281_clk>;
71 + clock-names = "xvclk";
73 + avdd-supply = <&ov9281_avdd>;
74 + dovdd-supply = <&ov9281_dovdd>;
75 + dvdd-supply = <&ov9281_dvdd>;
78 + ov9281_0: endpoint {
79 + remote-endpoint = <&csi1_ep>;
82 + clock-noncontinuous;
84 + /bits/ 64 <456000000>;
98 + remote-endpoint = <&ov9281_0>;
106 + target = <&i2c0if>;
115 + ov9281_avdd: fixedregulator@0 {
116 + compatible = "regulator-fixed";
117 + regulator-name = "ov9281_avdd";
118 + regulator-min-microvolt = <2800000>;
119 + regulator-max-microvolt = <2800000>;
120 + gpio = <&gpio 41 GPIO_ACTIVE_HIGH>;
121 + enable-active-high;
123 + ov9281_dovdd: fixedregulator@1 {
124 + compatible = "regulator-fixed";
125 + regulator-name = "ov9281_dovdd";
126 + regulator-min-microvolt = <1800000>;
127 + regulator-max-microvolt = <1800000>;
129 + ov9281_dvdd: fixedregulator@2 {
130 + compatible = "regulator-fixed";
131 + regulator-name = "ov9281_dvdd";
132 + regulator-min-microvolt = <1200000>;
133 + regulator-max-microvolt = <1200000>;
135 + ov9281_clk: ov9281-clk {
136 + compatible = "fixed-clock";
137 + #clock-cells = <0>;
138 + clock-frequency = <24000000>;
144 + target = <&i2c0mux>;
151 + target-path="/__overrides__";
153 + cam0-pwdn-ctrl = <&ov9281_avdd>,"gpio:0";
154 + cam0-pwdn = <&ov9281_avdd>,"gpio:4";