23a2fb9c26636c9957550132886fb1c131ce9fbc
[openwrt/openwrt.git] /
1 From 7d2efa734da00de05c8a58688da28cf1e380ef3a Mon Sep 17 00:00:00 2001
2 From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
3 Date: Sat, 4 Jul 2020 03:04:38 +0300
4 Subject: [PATCH] dt/dtoverlays: ov5647: Add parameter to set camera
5 module rotation
6
7 Add a rotation DT overlay parameter to allow specifying the camera
8 module mounting rotation.
9
10 Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
11 ---
12 arch/arm/boot/dts/overlays/README | 5 +++--
13 arch/arm/boot/dts/overlays/ov5647-overlay.dts | 6 ++++++
14 2 files changed, 9 insertions(+), 2 deletions(-)
15
16 --- a/arch/arm/boot/dts/overlays/README
17 +++ b/arch/arm/boot/dts/overlays/README
18 @@ -1809,8 +1809,9 @@ Name: ov5647
19 Info: Omnivision OV5647 camera module.
20 Uses Unicam 1, which is the standard camera connector on most Pi
21 variants.
22 -Load: dtoverlay=ov5647
23 -Params: <None>
24 +Load: dtoverlay=ov5647,<param>=<val>
25 +Params: rotation Mounting rotation of the camera sensor (0 or
26 + 180, default 0)
27
28
29 Name: ov7251
30 --- a/arch/arm/boot/dts/overlays/ov5647-overlay.dts
31 +++ b/arch/arm/boot/dts/overlays/ov5647-overlay.dts
32 @@ -21,6 +21,8 @@
33 pwdn-gpios = <&gpio 41 1>, <&gpio 32 1>;
34 clocks = <&ov5647_clk>;
35
36 + rotation = <0>;
37 +
38 port {
39 ov5647_0: endpoint {
40 remote-endpoint = <&csi1_ep>;
41 @@ -83,4 +85,8 @@
42 };
43 };
44 };
45 +
46 + __overrides__ {
47 + rotation = <&ov5647>,"rotation:0";
48 + };
49 };