From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id BECBAC433F5 for ; Wed, 18 May 2022 13:55:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238258AbiERNzo (ORCPT ); Wed, 18 May 2022 09:55:44 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55890 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238386AbiERNzd (ORCPT ); Wed, 18 May 2022 09:55:33 -0400 Received: from relay03.th.seeweb.it (relay03.th.seeweb.it [5.144.164.164]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A840F1C83E1 for ; Wed, 18 May 2022 06:55:28 -0700 (PDT) Received: from [10.1.250.9] (riviera.nat.ds.pw.edu.pl [194.29.137.1]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by m-r1.th.seeweb.it (Postfix) with ESMTPSA id 9E1901F6CD; Wed, 18 May 2022 15:55:26 +0200 (CEST) Message-ID: <58af3b06-97fe-fd29-b6e3-fa68737b1d96@somainline.org> Date: Wed, 18 May 2022 15:55:26 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.9.0 Subject: Re: [PATCH 1/1] arm64: dts: qcom: qrb5165-rb5: Enable the IMX577 on cam1 To: Bryan O'Donoghue , robert.foss@linaro.org, todor.too@gmail.com, agross@kernel.org, bjorn.andersson@linaro.org Cc: vladimir.zapolskiy@linaro.org, mchehab@kernel.org, robh+dt@kernel.org, krzk+dt@kernel.org, linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, mmitkov@quicinc.com, jgrahsl@snap.com, hfink@snap.com References: <20220518133004.342775-1-bryan.odonoghue@linaro.org> <20220518133004.342775-2-bryan.odonoghue@linaro.org> From: Konrad Dybcio In-Reply-To: <20220518133004.342775-2-bryan.odonoghue@linaro.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Hi! On 18/05/2022 15:30, Bryan O'Donoghue wrote: > The IMX577 is on CCI1/CSI2 providing four lanes of camera data. Commit says IMX577, code says IMX412. > > An example media-ctl pipeline is: > > media-ctl --reset > media-ctl -v -d /dev/media0 -V '"imx412 '20-001a'":0[fmt:SRGGB10/4056x3040 field:none]' > media-ctl -V '"msm_csiphy2":0[fmt:SRGGB10/4056x3040]' > media-ctl -V '"msm_csid0":0[fmt:SRGGB10/4056x3040]' > media-ctl -V '"msm_vfe0_rdi0":0[fmt:SRGGB10/4056x3040]' > media-ctl -l '"msm_csiphy2":1->"msm_csid0":0[1]' > media-ctl -l '"msm_csid0":1->"msm_vfe0_rdi0":0[1]' > > yavta -B capture-mplane -c -I -n 5 -f SRGGB10P -s 4056x3040 -F /dev/video0 > > Signed-off-by: Bryan O'Donoghue > --- > arch/arm64/boot/dts/qcom/qrb5165-rb5.dts | 98 ++++++++++++++++++++++++ > 1 file changed, 98 insertions(+) > > diff --git a/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts b/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts > index 0e63f707b911..48b31790c434 100644 > --- a/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts > +++ b/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts > @@ -1203,6 +1203,43 @@ sdc2_card_det_n: sd-card-det-n { > function = "gpio"; > bias-pull-up; > }; > + > + cam2_default: cam2-default { > + rst { > + pins = "gpio78"; > + function = "gpio"; > + > + drive-strength = <2>; > + bias-disable; Other pins in this DT don't have a newline between function and drive-strength, please remove it for consistency. > + }; > + > + mclk { > + pins = "gpio96"; > + function = "cam_mclk"; > + > + drive-strength = <16>; > + bias-disable; > + }; > + }; > + > + cam2_suspend: cam2-suspend { > + rst { > + pins = "gpio78"; > + function = "gpio"; > + > + drive-strength = <2>; > + bias-pull-down; > + output-low; > + }; > + > + mclk { > + pins = "gpio96"; > + function = "cam_mclk"; > + > + drive-strength = <2>; > + bias-disable; > + }; > + }; > }; > > &uart12 { > @@ -1294,3 +1331,64 @@ &qup_spi0_data_clk { > drive-strength = <6>; > bias-disable; > }; > + > +&camcc { > + status = "okay"; > +}; It's enabled by default. > + > +&camss { > + status = "okay"; > + vdda-phy-supply = <&vreg_l5a_0p88>; > + vdda-pll-supply = <&vreg_l9a_1p2>; > + > + ports { Maybe the port definitions along with #-cells here and on camss could be moved to the SoC DTSI? > + #address-cells = <1>; > + #size-cells = <0>; > + > + /* The port index denotes CSIPHY id i.e. csiphy2 */ > + port@2 { > + reg = <2>; > + csiphy2_ep: endpoint { > + clock-lanes = <7>; > + data-lanes = <0 1 2 3>; > + remote-endpoint = <&imx412_ep>; > + }; > + > + }; > + }; > +}; > + > +&cci1 { > + status = "okay"; > +}; > + > +&cci1_i2c0 { > + camera@1a { > + compatible = "sony,imx412"; > + reg = <0x1a>; > + > + reset-gpios = <&tlmm 78 GPIO_ACTIVE_LOW>; > + pinctrl-names = "default", "suspend"; > + pinctrl-0 = <&cam2_default>; > + pinctrl-1 = <&cam2_suspend>; > + > + clocks = <&camcc CAM_CC_MCLK2_CLK>; > + assigned-clocks = <&camcc CAM_CC_MCLK2_CLK>; > + assigned-clock-rates = <24000000>; > + > + power-domains = <&camcc TITAN_TOP_GDSC>; > + dovdd-supply = <&vreg_l7f_1p8>; > + avdd-supply = <&vdc_5v>; > + dvdd-supply = <&vdc_5v>; > + > + status = "okay"; It's enabled by default. Konrad > + port { > + imx412_ep: endpoint { > + clock-lanes = <1>; > + link-frequencies = /bits/ 64 <600000000>; > + data-lanes = <1 2 3 4>; > + remote-endpoint = <&csiphy2_ep>; > + }; > + }; > + }; > +}; >