Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

arm64: dts: rockchip: cleanup khadas edge 2 devicetree #165

Merged
Merged
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
5 changes: 5 additions & 0 deletions arch/arm64/boot/dts/rockchip/overlay/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,11 @@ dtbo-$(CONFIG_ARCH_ROCKCHIP) += \
yy3568-display-dsi1.dtbo \
yy3568-display-edp.dtbo \
yy3568-sata2.dtbo \
khadas-edge2-display-dsi0.dtbo \
khadas-edge2-display-dsi1.dtbo \
khadas-edge2-cam1.dtbo \
khadas-edge2-cam2.dtbo \
khadas-edge2-cam3.dtbo \
rockchip-rk3588-opp-oc-24ghz.dtbo \
rk3588-can0-m0.dtbo \
rk3588-can1-m0.dtbo \
Expand Down
233 changes: 233 additions & 0 deletions arch/arm64/boot/dts/rockchip/overlay/khadas-edge2-cam1.dts
Original file line number Diff line number Diff line change
@@ -0,0 +1,233 @@
/dts-v1/;
/plugin/;

#include <dt-bindings/clock/rk3588-cru.h>
#include <dt-bindings/power/rk3588-power.h>
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/pinctrl/rockchip.h>

/ {
fragment@0 {
target = <&mipi_dcphy1>;

__overlay__ {
status = "okay";
};
};

fragment@1 {
target = <&csi2_dcphy1>;

__overlay__ {
status = "okay";

ports {
#address-cells = <1>;
#size-cells = <0>;
port@0 {
reg = <0>;
#address-cells = <1>;
#size-cells = <0>;

mipi_in_dcphy1: endpoint@1 {
reg = <1>;
remote-endpoint = <&imx415f_out1>;
data-lanes = <1 2 3 4>;
};
};

port@1 {
reg = <1>;
#address-cells = <1>;
#size-cells = <0>;

csidcphy1_out: endpoint@0 {
reg = <0>;
remote-endpoint = <&mipi1_csi2_input>;
};
};
};
};
};

fragment@2 {
target = <&mipi1_csi2>;

__overlay__ {
status = "okay";

ports {
#address-cells = <1>;
#size-cells = <0>;

port@0 {
reg = <0>;
#address-cells = <1>;
#size-cells = <0>;

mipi1_csi2_input: endpoint@1 {
reg = <1>;
remote-endpoint = <&csidcphy1_out>;
};
};

port@1 {
reg = <1>;
#address-cells = <1>;
#size-cells = <0>;

mipi1_csi2_output: endpoint@0 {
reg = <0>;
remote-endpoint = <&cif_mipi_in1>;
};
};
};
};
};

fragment@3 {
target = <&rkcif_mipi_lvds1>;

__overlay__ {
status = "okay";

port {
cif_mipi_in1: endpoint {
remote-endpoint = <&mipi1_csi2_output>;
};
};
};
};

fragment@4 {
target = <&rkcif_mipi_lvds1_sditf>;

__overlay__ {
status = "okay";

port {
mipi1_lvds_sditf: endpoint {
remote-endpoint = <&isp0_vir1>;
};
};
};
};

fragment@5 {
target = <&rkisp0_vir1>;

__overlay__ {
status = "okay";

port {
#address-cells = <1>;
#size-cells = <0>;

isp0_vir1: endpoint@0 {
reg = <0>;
remote-endpoint = <&mipi1_lvds_sditf>;
};
};
};
};

fragment@6 {
target = <&i2c3>;

__overlay__ {
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <&i2c3m0_xfer>;

dw9714f: dw9714f@c {
compatible = "dongwoon,dw9714";
status = "okay";
reg = <0x0c>;
pinctrl-names = "focusf_gpios";
pinctrl-0 = <&focusf_gpio>;
focus-gpios = <&gpio1 RK_PA1 GPIO_ACTIVE_HIGH>;
rockchip,vcm-start-current = <20>;
rockchip,vcm-rated-current = <76>;
rockchip,vcm-step-mode = <0>;
rockchip,camera-module-index = <1>;
rockchip,camera-module-facing = "front";
};

imx415f: imx415f@1a {
compatible = "sony,imx415";
status = "okay";
reg = <0x1a>;
clocks = <&cru CLK_MIPI_CAMARAOUT_M2>;
clock-names = "xvclk";
power-domains = <&power RK3588_PD_VI>;
pinctrl-names = "default", "camf_gpios";
pinctrl-0 = <&mipim1_camera2_clk>, <&camf_gpio>;
rockchip,grf = <&sys_grf>;
reset-gpios = <&gpio3 RK_PC6 GPIO_ACTIVE_LOW>;
pwdn-gpios = <&gpio3 RK_PC5 GPIO_ACTIVE_HIGH>;
rockchip,camera-module-index = <1>;
rockchip,camera-module-facing = "front";
rockchip,camera-module-name = "CMK-OT2022-PX1";
rockchip,camera-module-lens-name = "IR0147-50IRC-8M-F20";
lens-focus = <&dw9714f>;
port {
imx415f_out1: endpoint {
remote-endpoint = <&mipi_in_dcphy1>;
data-lanes = <1 2 3 4>;
};
};
};
};
};

fragment@7 {
target = <&pinctrl>;

__overlay__ {
cam1 {
camf_gpio: camf-gpio {
rockchip,pins =
<3 RK_PC6 RK_FUNC_GPIO &pcfg_pull_none>,
<3 RK_PC5 RK_FUNC_GPIO &pcfg_pull_none>;
};

focusf_gpio: focusf-gpio {
rockchip,pins =
<1 RK_PA1 RK_FUNC_GPIO &pcfg_pull_none>;
};
};
};
};

fragment@8 {
target = <&rkcif>;

__overlay__ {
status = "okay";
};
};

fragment@9 {
target = <&rkcif_mmu>;

__overlay__ {
status = "okay";
};
};

fragment@10 {
target = <&rkisp0>;

__overlay__ {
status = "okay";
};
};

fragment@11 {
target = <&isp0_mmu>;

__overlay__ {
status = "okay";
};
};
};
Loading
Loading