From 340040b0e82fb0cede3957d2a55706a8574d8e0e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Apitzsch?= Date: Fri, 6 Oct 2023 20:13:49 +0200 Subject: [PATCH 1/2] arm64: dts: qcom: msm8916-longcheer-l8910: add rear camera support MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add rear camera support, using imx214 sensor. Signed-off-by: André Apitzsch --- .../boot/dts/qcom/msm8916-longcheer-l8910.dts | 90 +++++++++++++++++++ 1 file changed, 90 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8910.dts b/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8910.dts index 7330240d88dd7d..9b248245703c5c 100644 --- a/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8910.dts +++ b/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8910.dts @@ -45,6 +45,26 @@ default-brightness-level = <255>; }; + cam_vana_rear_vreg: cam-vana-rear-regulator { + compatible = "regulator-fixed"; + regulator-name = "cam_vana_rear_vreg"; + startup-delay-us = <0>; + enable-active-high; + gpio = <&tlmm 34 GPIO_ACTIVE_HIGH>; + pinctrl-0 = <&imx214_vana_default>; + pinctrl-names = "default"; + }; + + cam_vdig_rear_vreg: cam-vdig-rear-regulator { + compatible = "regulator-fixed"; + regulator-name = "cam_vdig_rear_vreg"; + startup-delay-us = <0>; + enable-active-high; + gpio = <&tlmm 31 GPIO_ACTIVE_HIGH>; + pinctrl-0 = <&imx214_vdig_default>; + pinctrl-names = "default"; + }; + flash-led-controller { compatible = "ocs,ocp8110"; enable-gpios = <&tlmm 49 GPIO_ACTIVE_HIGH>; @@ -280,6 +300,56 @@ pinctrl-names = "default", "sleep"; }; +&camss { + status = "okay"; + + ports { + port@0 { + reg = <0>; + csiphy0_ep: endpoint { + clock-lanes = <1>; + data-lanes = <0 2 3 4>; + remote-endpoint = <&imx214_ep>; + }; + }; + }; +}; + +&cci { + status = "okay"; +}; + +&cci_i2c0 { + camera@10 { + compatible = "sony,imx214"; + reg = <0x10>; + + clocks = <&gcc GCC_CAMSS_MCLK0_CLK>; + assigned-clocks = <&gcc GCC_CAMSS_MCLK0_CLK>; + assigned-clock-rates = <23880000>; + + enable-gpios = <&tlmm 35 GPIO_ACTIVE_HIGH>; + + vdda-supply = <&cam_vana_rear_vreg>; + vddd-supply = <&cam_vdig_rear_vreg>; + vdddo-supply = <&pm8916_l6>; + + pinctrl-0 = <&camera_rear_default>; + pinctrl-names = "default"; + + orientation = <1>; + rotation = <270>; + + port { + imx214_ep: endpoint { + data-lanes = <1 2 3 4>; + link-frequencies = /bits/ 64 <597000000>; + remote-endpoint = <&csiphy0_ep>; + }; + }; + }; +}; + &gpu { status = "okay"; }; @@ -458,6 +528,22 @@ bias-pull-up; }; + imx214_vana_default: imx214-vana-default-state { + pins = "gpio34"; + function = "gpio"; + + drive-strength = <2>; + bias-disable; + }; + + imx214_vdig_default: imx214-vdig-default-state { + pins = "gpio31"; + function = "gpio"; + + drive-strength = <2>; + bias-disable; + }; + mag_reset_default: mag-reset-default-state { pins = "gpio111"; function = "gpio"; @@ -542,3 +628,7 @@ qcom,dtest = <1>; }; }; + +&camera_rear_default { + /delete-node/ pwdn-pins; +}; From 38a50132a8dc539ba8c72ac52174c0806ebb17d4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Apitzsch?= Date: Tue, 27 Aug 2024 22:19:13 +0200 Subject: [PATCH 2/2] squash! MSM8916: arm64: configs: Add msm8916_defconfig (v86) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit CONFIG_VIDEO_IMX214=m Signed-off-by: André Apitzsch --- arch/arm64/configs/msm8916_defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm64/configs/msm8916_defconfig b/arch/arm64/configs/msm8916_defconfig index 8d09353c14501f..09b7eaf54c62b2 100644 --- a/arch/arm64/configs/msm8916_defconfig +++ b/arch/arm64/configs/msm8916_defconfig @@ -273,6 +273,7 @@ CONFIG_V4L_PLATFORM_DRIVERS=y CONFIG_V4L_MEM2MEM_DRIVERS=y CONFIG_VIDEO_QCOM_CAMSS=m CONFIG_VIDEO_QCOM_VENUS=m +CONFIG_VIDEO_IMX214=m CONFIG_DRM=y CONFIG_DRM_SIMPLEDRM=y CONFIG_DRM_MSM=m