Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions arch/arm/boot/dts/overlays/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,7 @@ dtbo-$(CONFIG_ARCH_BCM2835) += \
imx500.dtbo \
imx500-pi5.dtbo \
imx519.dtbo \
imx662.dtbo \
imx708.dtbo \
interludeaudio-analog.dtbo \
interludeaudio-digital.dtbo \
Expand Down
21 changes: 21 additions & 0 deletions arch/arm/boot/dts/overlays/README
Original file line number Diff line number Diff line change
Expand Up @@ -3097,6 +3097,27 @@ Params: rotation Mounting rotation of the camera sensor (0 or
but vcm=off will disable.


Name: imx290
Info: Sony IMX662 camera module.
Uses Unicam 1, which is the standard camera connector on most Pi
variants.
Load: dtoverlay=imx662,<param>
Params: 4lane Enable 4 CSI2 lanes. This requires a Compute
Module (1, 3, 4, or 5) or Pi 5.
clock-frequency Sets the clock frequency to match that used on
the board. Default 24MHz
mono Denote that the module is a mono sensor.
orientation Sensor orientation (0 = front, 1 = rear,
2 = external, default external)
rotation Mounting rotation of the camera sensor (0 or
180, default 0)
media-controller Configure use of Media Controller API for
configuring the sensor (default on)
cam0 Adopt the default configuration for CAM0 on a
Compute Module (CSI0, i2c_vc, and cam0_reg).
vcm Enable a VCM focus drive on the sensor.


Name: imx708
Info: Sony IMX708 camera module.
Uses Unicam 1, which is the standard camera connector on most Pi
Expand Down
114 changes: 114 additions & 0 deletions arch/arm/boot/dts/overlays/imx662-overlay.dts
Original file line number Diff line number Diff line change
@@ -0,0 +1,114 @@
// SPDX-License-Identifier: GPL-2.0-only
// Definitions for IMX662 camera module on VC I2C bus
/dts-v1/;
/plugin/;

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

/{
compatible = "brcm,bcm2835";

fragment@0 {
target = <&i2c0if>;
__overlay__ {
status = "okay";
};
};

clk_frag: fragment@1 {
target = <&cam1_clk>;
__overlay__ {
status = "okay";
clock-frequency = <24000000>;
};
};

fragment@2 {
target = <&i2c0mux>;
__overlay__ {
status = "okay";
};
};

i2c_frag: fragment@100 {
target = <&i2c_csi_dsi>;
__overlay__ {
#address-cells = <1>;
#size-cells = <0>;
status = "okay";

#include "imx662.dtsi"

vcm: ad5398@c {
compatible = "adi,ad5398";
reg = <0x0c>;
status = "disabled";
VANA-supply = <&cam1_reg>;
};
};
};

csi_frag: fragment@101 {
target = <&csi1>;
csi: __overlay__ {
status = "okay";

port {
csi_ep: endpoint {
remote-endpoint = <&cam_endpoint>;
clock-lanes = <0>;
data-lanes = <1 2>;
clock-noncontinuous;
};
};
};
};

fragment@102 {
target = <&csi1>;
__dormant__ {
compatible = "brcm,bcm2835-unicam-legacy";
};
};

fragment@201 {
target = <&csi_ep>;
__dormant__ {
data-lanes = <1 2 3 4>;
};
};

fragment@202 {
target = <&cam_endpoint>;
__dormant__ {
data-lanes = <1 2 3 4>;
link-frequencies =
/bits/ 64 <297000000>;
};
};

__overrides__ {
rotation = <&cam_node>,"rotation:0";
orientation = <&cam_node>,"orientation:0";
media-controller = <0>,"!102";
cam0 = <&i2c_frag>, "target:0=",<&i2c_csi_dsi0>,
<&csi_frag>, "target:0=",<&csi0>,
<&clk_frag>, "target:0=",<&cam0_clk>,
<&cam_node>, "clocks:0=",<&cam0_clk>,
<&cam_node>, "VANA-supply:0=",<&cam0_reg>,
<&vcm>, "VANA-supply:0=", <&cam0_reg>;
vcm = <&vcm>, "status=okay",
<&cam_node>,"lens-focus:0=", <&vcm>;
4lane = <0>, "+201+202";
clock-frequency = <&clk_frag>,"clock-frequency:0",
<&cam_node>,"clock-frequency:0";
};
};

&cam_node {
status = "okay";
};

&cam_endpoint {
remote-endpoint = <&csi_ep>;
};
28 changes: 28 additions & 0 deletions arch/arm/boot/dts/overlays/imx662.dtsi
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
// Fragment that configures an imx662

cam_node: imx662@10 {
compatible = "sony,imx662aaqr";
reg = <0x1a>;
status = "disabled";

clocks = <&cam1_clk>;
clock-names = "xclk";
clock-frequency = <24000000>;

vdda-supply = <&cam1_reg>; /* 2.8v */
vddd-supply = <&cam_dummy_reg>; /* 1.8v */
vdddo-supply = <&cam_dummy_reg>;/* 1.2v */

rotation = <180>;
orientation = <2>;

port {
cam_endpoint: endpoint {
clock-lanes = <0>;
data-lanes = <1 2>;
clock-noncontinuous;
link-frequencies =
/bits/ 64 <594000000>;
};
};
};
1 change: 1 addition & 0 deletions arch/arm/configs/bcm2709_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -956,6 +956,7 @@ CONFIG_VIDEO_IMX415=m
CONFIG_VIDEO_IMX477=m
CONFIG_VIDEO_IMX500=m
CONFIG_VIDEO_IMX519=m
CONFIG_VIDEO_IMX662=m
CONFIG_VIDEO_IMX708=m
CONFIG_VIDEO_MIRA220=m
CONFIG_VIDEO_MT9V011=m
Expand Down
1 change: 1 addition & 0 deletions arch/arm/configs/bcm2711_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -995,6 +995,7 @@ CONFIG_VIDEO_IMX415=m
CONFIG_VIDEO_IMX477=m
CONFIG_VIDEO_IMX500=m
CONFIG_VIDEO_IMX519=m
CONFIG_VIDEO_IMX662=m
CONFIG_VIDEO_IMX708=m
CONFIG_VIDEO_MIRA220=m
CONFIG_VIDEO_MT9V011=m
Expand Down
1 change: 1 addition & 0 deletions arch/arm/configs/bcmrpi_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -949,6 +949,7 @@ CONFIG_VIDEO_IMX415=m
CONFIG_VIDEO_IMX477=m
CONFIG_VIDEO_IMX500=m
CONFIG_VIDEO_IMX519=m
CONFIG_VIDEO_IMX662=m
CONFIG_VIDEO_IMX708=m
CONFIG_VIDEO_MIRA220=m
CONFIG_VIDEO_MT9V011=m
Expand Down
1 change: 1 addition & 0 deletions arch/arm64/configs/bcm2711_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -1047,6 +1047,7 @@ CONFIG_VIDEO_IMX415=m
CONFIG_VIDEO_IMX477=m
CONFIG_VIDEO_IMX500=m
CONFIG_VIDEO_IMX519=m
CONFIG_VIDEO_IMX662=m
CONFIG_VIDEO_IMX708=m
CONFIG_VIDEO_MIRA220=m
CONFIG_VIDEO_MT9V011=m
Expand Down
1 change: 1 addition & 0 deletions arch/arm64/configs/bcm2712_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -1049,6 +1049,7 @@ CONFIG_VIDEO_IMX415=m
CONFIG_VIDEO_IMX477=m
CONFIG_VIDEO_IMX500=m
CONFIG_VIDEO_IMX519=m
CONFIG_VIDEO_IMX662=m
CONFIG_VIDEO_IMX708=m
CONFIG_VIDEO_MIRA220=m
CONFIG_VIDEO_MT9V011=m
Expand Down
11 changes: 11 additions & 0 deletions drivers/media/i2c/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -324,6 +324,17 @@ config VIDEO_IMX519
To compile this driver as a module, choose M here: the
module will be called IMX519.

config VIDEO_IMX662
tristate "Sony IMX662 sensor support"
select REGMAP_I2C
select V4L2_CCI_I2C
help
This is a Video4Linux2 sensor driver for the Sony
IMX662 camera sensor.

To compile this driver as a module, choose M here: the
module will be called imx662.

config VIDEO_IMX708
tristate "Sony IMX708 sensor support"
depends on I2C && VIDEO_DEV
Expand Down
1 change: 1 addition & 0 deletions drivers/media/i2c/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ obj-$(CONFIG_VIDEO_IMX415) += imx415.o
obj-$(CONFIG_VIDEO_IMX477) += imx477.o
obj-$(CONFIG_VIDEO_IMX500) += imx500.o
obj-$(CONFIG_VIDEO_IMX519) += imx519.o
obj-$(CONFIG_VIDEO_IMX662) += imx662.o
obj-$(CONFIG_VIDEO_IMX708) += imx708.o
obj-$(CONFIG_VIDEO_IR_I2C) += ir-kbd-i2c.o
obj-$(CONFIG_VIDEO_IRS1125) += irs1125.o
Expand Down
Loading
Loading