forked from radxa-pkg/radxa-overlays
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request radxa-pkg#337 from Ken-Vamrs/main
add radxa camera 8m 219 for rock 5a/b
- Loading branch information
Showing
3 changed files
with
372 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
184 changes: 184 additions & 0 deletions
184
arch/arm64/boot/dts/rockchip/overlays/rock-5a-radxa-camera-8m-219.dts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,184 @@ | ||
/dts-v1/; | ||
/plugin/; | ||
|
||
#include <dt-bindings/gpio/gpio.h> | ||
#include <dt-bindings/pinctrl/rockchip.h> | ||
|
||
/ { | ||
metadata { | ||
title ="Enable Radxa Camera 8M 219"; | ||
compatible = "radxa,rock-5a", "radxa,rock-5c"; | ||
category = "camera"; | ||
exclusive = "csi2_dphy0"; | ||
description = "Enable Radxa Camera 8M 219."; | ||
}; | ||
}; | ||
|
||
&{/} { | ||
camera_pwdn_gpio: camera-pwdn-gpio { | ||
compatible = "regulator-fixed"; | ||
regulator-name = "camera_pwdn_gpio"; | ||
regulator-always-on; | ||
regulator-boot-on; | ||
enable-active-high; | ||
gpio = <&gpio1 RK_PD3 GPIO_ACTIVE_HIGH>; | ||
pinctrl-names = "default"; | ||
pinctrl-0 = <&cam_pwdn_gpio>; | ||
}; | ||
|
||
clk_cam_24m: external-camera-clock-24m { | ||
compatible = "fixed-clock"; | ||
clock-frequency = <24000000>; | ||
clock-output-names = "clk_cam_24m"; | ||
#clock-cells = <0>; | ||
}; | ||
}; | ||
|
||
&i2c3 { | ||
status = "okay"; | ||
|
||
camera_imx219: camera-imx219@10 { | ||
compatible = "sony,imx219"; | ||
reg = <0x10>; | ||
|
||
clocks = <&clk_cam_24m>; | ||
clock-names = "xvclk"; | ||
|
||
rockchip,camera-module-index = <0>; | ||
rockchip,camera-module-facing = "back"; | ||
rockchip,camera-module-name = "RADXA-CAMERA-8M"; | ||
rockchip,camera-module-lens-name = "default"; | ||
|
||
port { | ||
imx219_out0: endpoint { | ||
remote-endpoint = <&mipidphy0_in_ucam1>; | ||
data-lanes = <1 2>; | ||
}; | ||
}; | ||
}; | ||
}; | ||
|
||
&csi2_dphy0_hw { | ||
status = "okay"; | ||
}; | ||
|
||
&csi2_dphy0 { | ||
status = "okay"; | ||
|
||
ports { | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
port@0 { | ||
reg = <0>; | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
mipidphy0_in_ucam1: endpoint@2 { | ||
reg = <2>; | ||
remote-endpoint = <&imx219_out0>; | ||
data-lanes = <1 2>; | ||
}; | ||
}; | ||
|
||
port@1 { | ||
reg = <1>; | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
csidphy0_out: endpoint@0 { | ||
reg = <0>; | ||
remote-endpoint = <&mipi2_csi2_input>; | ||
}; | ||
}; | ||
}; | ||
}; | ||
|
||
&mipi2_csi2 { | ||
status = "okay"; | ||
|
||
ports { | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
port@0 { | ||
reg = <0>; | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
mipi2_csi2_input: endpoint@1 { | ||
reg = <1>; | ||
remote-endpoint = <&csidphy0_out>; | ||
}; | ||
}; | ||
|
||
port@1 { | ||
reg = <1>; | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
mipi2_csi2_output: endpoint@0 { | ||
reg = <0>; | ||
remote-endpoint = <&cif_mipi2_in0>; | ||
}; | ||
}; | ||
}; | ||
}; | ||
|
||
&rkcif { | ||
status = "okay"; | ||
}; | ||
|
||
&rkcif_mipi_lvds2 { | ||
status = "okay"; | ||
|
||
port { | ||
cif_mipi2_in0: endpoint { | ||
remote-endpoint = <&mipi2_csi2_output>; | ||
}; | ||
}; | ||
}; | ||
|
||
&rkcif_mipi_lvds2_sditf { | ||
status = "okay"; | ||
|
||
port { | ||
mipi_lvds2_sditf: endpoint { | ||
remote-endpoint = <&isp0_vir0>; | ||
}; | ||
}; | ||
}; | ||
|
||
&rkcif_mmu { | ||
status = "okay"; | ||
}; | ||
|
||
&isp0_mmu { | ||
status = "okay"; | ||
}; | ||
|
||
&rkisp0 { | ||
status = "okay"; | ||
}; | ||
|
||
&rkisp0_vir0 { | ||
status = "okay"; | ||
|
||
port { | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
isp0_vir0: endpoint@0 { | ||
reg = <0>; | ||
remote-endpoint = <&mipi_lvds2_sditf>; | ||
}; | ||
}; | ||
}; | ||
|
||
&pinctrl { | ||
camera { | ||
cam_pwdn_gpio: cam-pwdn-gpio { | ||
rockchip,pins = <1 RK_PD3 RK_FUNC_GPIO &pcfg_pull_up>; | ||
}; | ||
}; | ||
}; |
186 changes: 186 additions & 0 deletions
186
arch/arm64/boot/dts/rockchip/overlays/rock-5b-radxa-camera-8m-219.dts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,186 @@ | ||
/dts-v1/; | ||
/plugin/; | ||
|
||
#include <dt-bindings/gpio/gpio.h> | ||
#include <dt-bindings/pinctrl/rockchip.h> | ||
|
||
/ { | ||
metadata { | ||
title ="Enable Radxa Camera 8M 219"; | ||
compatible = "radxa,rock-5b"; | ||
category = "camera"; | ||
exclusive = "csi2_dphy0"; | ||
description = "Enable Radxa Camera 8M 219."; | ||
}; | ||
}; | ||
|
||
&{/} { | ||
camera_pwdn_gpio: camera-pwdn-gpio { | ||
compatible = "regulator-fixed"; | ||
regulator-name = "camera_pwdn_gpio"; | ||
regulator-always-on; | ||
regulator-boot-on; | ||
enable-active-high; | ||
gpio = <&gpio1 RK_PB0 GPIO_ACTIVE_HIGH>; | ||
pinctrl-names = "default"; | ||
pinctrl-0 = <&cam_pwdn_gpio>; | ||
}; | ||
|
||
clk_cam_24m: external-camera-clock-24m { | ||
compatible = "fixed-clock"; | ||
clock-frequency = <24000000>; | ||
clock-output-names = "clk_cam_24m"; | ||
#clock-cells = <0>; | ||
}; | ||
}; | ||
|
||
&i2c3 { | ||
status = "okay"; | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
camera_imx219: camera-imx219@10 { | ||
compatible = "sony,imx219"; | ||
reg = <0x10>; | ||
|
||
clocks = <&clk_cam_24m>; | ||
clock-names = "xvclk"; | ||
|
||
rockchip,camera-module-index = <0>; | ||
rockchip,camera-module-facing = "back"; | ||
rockchip,camera-module-name = "RADXA-CAMERA-8M"; | ||
rockchip,camera-module-lens-name = "default"; | ||
|
||
port { | ||
imx219_out0: endpoint { | ||
remote-endpoint = <&mipidphy0_in_ucam1>; | ||
data-lanes = <1 2>; | ||
}; | ||
}; | ||
}; | ||
}; | ||
|
||
&csi2_dphy0_hw { | ||
status = "okay"; | ||
}; | ||
|
||
&csi2_dphy0 { | ||
status = "okay"; | ||
|
||
ports { | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
port@0 { | ||
reg = <0>; | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
mipidphy0_in_ucam1: endpoint@2 { | ||
reg = <2>; | ||
remote-endpoint = <&imx219_out0>; | ||
data-lanes = <1 2>; | ||
}; | ||
}; | ||
|
||
port@1 { | ||
reg = <1>; | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
csidphy0_out: endpoint@0 { | ||
reg = <0>; | ||
remote-endpoint = <&mipi2_csi2_input>; | ||
}; | ||
}; | ||
}; | ||
}; | ||
|
||
&mipi2_csi2 { | ||
status = "okay"; | ||
|
||
ports { | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
port@0 { | ||
reg = <0>; | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
mipi2_csi2_input: endpoint@1 { | ||
reg = <1>; | ||
remote-endpoint = <&csidphy0_out>; | ||
}; | ||
}; | ||
|
||
port@1 { | ||
reg = <1>; | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
mipi2_csi2_output: endpoint@0 { | ||
reg = <0>; | ||
remote-endpoint = <&cif_mipi2_in0>; | ||
}; | ||
}; | ||
}; | ||
}; | ||
|
||
&rkcif { | ||
status = "okay"; | ||
}; | ||
|
||
&rkcif_mipi_lvds2 { | ||
status = "okay"; | ||
|
||
port { | ||
cif_mipi2_in0: endpoint { | ||
remote-endpoint = <&mipi2_csi2_output>; | ||
}; | ||
}; | ||
}; | ||
|
||
&rkcif_mipi_lvds2_sditf { | ||
status = "okay"; | ||
|
||
port { | ||
mipi_lvds2_sditf: endpoint { | ||
remote-endpoint = <&isp0_vir0>; | ||
}; | ||
}; | ||
}; | ||
|
||
&rkcif_mmu { | ||
status = "okay"; | ||
}; | ||
|
||
&isp0_mmu { | ||
status = "okay"; | ||
}; | ||
|
||
&rkisp0 { | ||
status = "okay"; | ||
}; | ||
|
||
&rkisp0_vir0 { | ||
status = "okay"; | ||
|
||
port { | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
isp0_vir0: endpoint@0 { | ||
reg = <0>; | ||
remote-endpoint = <&mipi_lvds2_sditf>; | ||
}; | ||
}; | ||
}; | ||
|
||
&pinctrl { | ||
camera { | ||
cam_pwdn_gpio: cam-pwdn-gpio { | ||
rockchip,pins = <1 RK_PB0 RK_FUNC_GPIO &pcfg_pull_up>; | ||
}; | ||
}; | ||
}; |