Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp15235722rwd; Sun, 25 Jun 2023 13:08:07 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ55ebPyal0lOu7aKVJ3G4dESI6jy+GubBliN2rfgjAK+flLyqZ9I2OUnZHoEZ5c8GGjZdE/ X-Received: by 2002:a17:907:7293:b0:988:84e8:747c with SMTP id dt19-20020a170907729300b0098884e8747cmr18037503ejc.32.1687723687489; Sun, 25 Jun 2023 13:08:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687723687; cv=none; d=google.com; s=arc-20160816; b=wjOmwkPMaYnpydCq3hrra0mws2Jnau09IcOM61hAnltfCv9yxLPll145wiLdL0s8TG ZIRW4gxFGBYrEUmmx5lKEbRagxSaHZEsHbXTT6K53q4IiLLNOK9Dq/tgawLj7IrmRpAe 5HsPCGv8Rl//YoYMv/qpLBd/1wzDqHGoXZR6z0jK5dvjV96mNaX89A1OozqoniLgsa1d zAKQySTNs72HIe1Y3LUrmWqnTBEVTmE1gFF5glwosrAVrLCZ4rOZJoQEv7/APMmNLtcW /CDhRrz/UsnnjWQ85i/5l9Z0vJ9O5TnNgEE1PX6m2PxnHCCHoHTji922pZ9rExkSshN/ sqjw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=z8p4AjyIF4qga347NW8mwAzdp46g3tJwt+AAp9lQME4=; fh=djDN5Fva8FmLoU0DRmInJWrBHVIqjCqUczAQ4tJuB6I=; b=q+A9lpBv4VsTJfoRsZIw/hm+/NPf5BsMcNkX/uGPVAm6k7uO+R6OtgC8gVu+IK8p60 Hqs3rBVrPBjarDov8MJl1mD4Rdvph/U+xOJad8rEbKAW3i5VxTWvtUQBguLHqX6S/qZ4 IuzIx/LP21sGd9URxcJ762xFqWxST7CCaahaR61xPE5yO3TPi+Tcs6Uu85un3w7Qd2pp yO8mKqJXWXvntkT9eXPQ6E+EjExIv3sQF0T91UnWToN3uhEqSglEvMeo85rwiedeKHAT DSsEdz2gR/R7PvMAlJ4/VggN8rWL31tj2QLOHs5UP44RDDo+AEGZyRUQZtcob2nAYlJP 47AA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id qh11-20020a170906ecab00b0098e0739532fsi1559888ejb.732.2023.06.25.13.07.43; Sun, 25 Jun 2023 13:08:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229510AbjFYTgz (ORCPT + 99 others); Sun, 25 Jun 2023 15:36:55 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47316 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229452AbjFYTgy (ORCPT ); Sun, 25 Jun 2023 15:36:54 -0400 Received: from relay06.th.seeweb.it (relay06.th.seeweb.it [IPv6:2001:4b7a:2000:18::167]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 865EB197 for ; Sun, 25 Jun 2023 12:36:52 -0700 (PDT) Received: from SoMainline.org (94-211-6-86.cable.dynamic.v4.ziggo.nl [94.211.6.86]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by m-r2.th.seeweb.it (Postfix) with ESMTPSA id 00A623EECD; Sun, 25 Jun 2023 21:36:49 +0200 (CEST) Date: Sun, 25 Jun 2023 21:36:48 +0200 From: Marijn Suijten To: Konrad Dybcio Cc: Andy Gross , Bjorn Andersson , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Michael Turquette , Stephen Boyd , Rob Clark , Abhinav Kumar , Dmitry Baryshkov , Sean Paul , David Airlie , Daniel Vetter , Krishna Manikandan , ~postmarketos/upstreaming@lists.sr.ht, AngeloGioacchino Del Regno , Martin Botka , Jami Kettunen , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Krzysztof Kozlowski , linux-clk@vger.kernel.org, dri-devel@lists.freedesktop.org, freedreno@lists.freedesktop.org, Lux Aliaga Subject: Re: [PATCH 14/15] arm64: dts: qcom: sm6125: Add display hardware nodes Message-ID: References: <20230624-sm6125-dpu-v1-0-1d5a638cebf2@somainline.org> <20230624-sm6125-dpu-v1-14-1d5a638cebf2@somainline.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2023-06-24 04:05:07, Konrad Dybcio wrote: > On 24.06.2023 02:41, Marijn Suijten wrote: > > Add the DT nodes that describe the MDSS hardware on SM6125, containing > > one MDP (display controller) together with a single DSI and DSI PHY. No > > DisplayPort support is added for now. > > > > Signed-off-by: Marijn Suijten > > --- > > arch/arm64/boot/dts/qcom/sm6125.dtsi | 190 ++++++++++++++++++++++++++++++++++- > > 1 file changed, 186 insertions(+), 4 deletions(-) > > > > diff --git a/arch/arm64/boot/dts/qcom/sm6125.dtsi b/arch/arm64/boot/dts/qcom/sm6125.dtsi > > index 7d78b4e48ebe..6852dacf54e6 100644 > > --- a/arch/arm64/boot/dts/qcom/sm6125.dtsi > > +++ b/arch/arm64/boot/dts/qcom/sm6125.dtsi > > @@ -1204,16 +1204,198 @@ sram@4690000 { > > reg = <0x04690000 0x10000>; > > }; > > > > + mdss: display-subsystem@5e00000 { > > + compatible = "qcom,sm6125-mdss"; > > + reg = <0x05e00000 0x1000>; > > + reg-names = "mdss"; > > + > > + power-domains = <&dispcc MDSS_GDSC>; > > + > > + clocks = <&gcc GCC_DISP_AHB_CLK>, > > + <&dispcc DISP_CC_MDSS_AHB_CLK>, > > + <&dispcc DISP_CC_MDSS_MDP_CLK>; > > + clock-names = "iface", "ahb", "core"; > One per line would be nice Sure, it's all over the place elsewhere though. > > + > > + interrupts = ; > > + interrupt-controller; > > + #interrupt-cells = <1>; > > + > > + iommus = <&apps_smmu 0x400 0x0>; > > + > Every node has a different scramble of property orders :P > > To roughly align with what I ask most people to do (and what I should > work on codifying and automating ehhh) would be: Exactly. Until this automated - or even documented - there is barely any point to manually deal with this. > [compat] > [reg] > > [interrupt] Also interrupt-cells here, since that's only related to interrupt-controller; and not interrupts=<>;? > > [clock] > > [reset] > (btw there should be a MDSS_CORE reset at DISP_CC+0x2000, try writing 1 there > and see if MDSS dies) > > [opp] > [pd] > > [iommus] > [icc] > > [phy] > > [addresssizeranges] > > [status] Sure, have reordered them like this for v2. > > > + status = "disabled"; > > + > > + #address-cells = <1>; > > + #size-cells = <1>; > > + ranges; > > + > > + mdss_mdp: display-controller@5e01000 { > > + compatible = "qcom,sm6125-dpu"; > > + reg = <0x05e01000 0x83208>, > > + <0x05eb0000 0x2008>; > > + reg-names = "mdp", "vbif"; > > + > > + clocks = <&gcc GCC_DISP_HF_AXI_CLK>, > > + <&dispcc DISP_CC_MDSS_AHB_CLK>, > > + <&dispcc DISP_CC_MDSS_ROT_CLK>, > > + <&dispcc DISP_CC_MDSS_MDP_LUT_CLK>, > > + <&dispcc DISP_CC_MDSS_MDP_CLK>, > > + <&dispcc DISP_CC_MDSS_VSYNC_CLK>; > > + clock-names = "bus", > > + "iface", > > + "rot", > > + "lut", > > + "core", > > + "vsync"; > > + assigned-clocks = <&dispcc DISP_CC_MDSS_VSYNC_CLK>; > > + assigned-clock-rates = <19200000>; > > + > > + operating-points-v2 = <&mdp_opp_table>; > > + power-domains = <&rpmpd SM6125_VDDCX>; > > + > > + interrupt-parent = <&mdss>; > > + interrupts = <0>; > > + > > + ports { > > + #address-cells = <1>; > > + #size-cells = <0>; > > + > > + port@0 { > > + reg = <0>; > > + dpu_intf1_out: endpoint { > > + remote-endpoint = <&mdss_dsi0_in>; > > + }; > > + }; > > + }; > > + > > + mdp_opp_table: opp-table { > > + compatible = "operating-points-v2"; > > + > > + opp-192000000 { > > + opp-hz = /bits/ 64 <192000000>; > > + required-opps = <&rpmpd_opp_low_svs>; > > + }; > > + > > + opp-256000000 { > > + opp-hz = /bits/ 64 <256000000>; > > + required-opps = <&rpmpd_opp_svs>; > > + }; > > + > > + opp-307200000 { > > + opp-hz = /bits/ 64 <307200000>; > > + required-opps = <&rpmpd_opp_svs_plus>; > > + }; > > + > > + opp-384000000 { > > + opp-hz = /bits/ 64 <384000000>; > > + required-opps = <&rpmpd_opp_nom>; > > + }; > > + > > + opp-400000000 { > > + opp-hz = /bits/ 64 <400000000>; > > + required-opps = <&rpmpd_opp_turbo>; > > + }; > > + }; > > + }; > > + > > + mdss_dsi0: dsi@5e94000 { > > + compatible = "qcom,sm6125-dsi-ctrl", "qcom,mdss-dsi-ctrl"; > > + reg = <0x05e94000 0x400>; > > + reg-names = "dsi_ctrl"; > > + > > + interrupt-parent = <&mdss>; > > + interrupts = <4>; > > + > > + clocks = <&dispcc DISP_CC_MDSS_BYTE0_CLK>, > > + <&dispcc DISP_CC_MDSS_BYTE0_INTF_CLK>, > > + <&dispcc DISP_CC_MDSS_PCLK0_CLK>, > > + <&dispcc DISP_CC_MDSS_ESC0_CLK>, > > + <&dispcc DISP_CC_MDSS_AHB_CLK>, > > + <&gcc GCC_DISP_HF_AXI_CLK>; > > + clock-names = "byte", > > + "byte_intf", > > + "pixel", > > + "core", > > + "iface", > > + "bus"; > > + > > + assigned-clocks = <&dispcc DISP_CC_MDSS_BYTE0_CLK_SRC>, > > + <&dispcc DISP_CC_MDSS_PCLK0_CLK_SRC>; > > + assigned-clock-parents = <&mdss_dsi0_phy 0>, <&mdss_dsi0_phy 1>; > > + > > + operating-points-v2 = <&dsi_opp_table>; > > + power-domains = <&rpmpd SM6125_VDDMX>; > CX Downstream says MX (and only on the phy... but it is the dsi node that defines the corresponding rpmpd opps). Do you have a source to back this up? > > > + > > + phys = <&mdss_dsi0_phy>; > > + phy-names = "dsi"; > > + > > + status = "disabled"; > > + > > + #address-cells = <1>; > > + #size-cells = <0>; > > + > > + ports { > > + #address-cells = <1>; > > + #size-cells = <0>; > > + > > + port@0 { > > + reg = <0>; > > + mdss_dsi0_in: endpoint { > > + remote-endpoint = <&dpu_intf1_out>; > > + }; > > + }; > > + > > + port@1 { > > + reg = <1>; > > + mdss_dsi0_out: endpoint { > > + }; > > + }; > > + }; > > + > > + dsi_opp_table: opp-table { > > + compatible = "operating-points-v2"; > > + > > + opp-164000000 { > > + opp-hz = /bits/ 64 <164000000>; > > + required-opps = <&rpmpd_opp_low_svs>; > > + }; > > + > > + opp-187500000 { > > + opp-hz = /bits/ 64 <187500000>; > > + required-opps = <&rpmpd_opp_svs>; > > + }; > > + }; > > + }; > > + > > + mdss_dsi0_phy: phy@5e94400 { > > + compatible = "qcom,dsi-phy-14nm-6125"; > > + reg = <0x05e94400 0x100>, > > + <0x05e94500 0x300>, > > + <0x05e94800 0x188>; > > + reg-names = "dsi_phy", > > + "dsi_phy_lane", > > + "dsi_pll"; > > + > > + #clock-cells = <1>; > > + #phy-cells = <0>; > > + > > + clocks = <&dispcc DISP_CC_MDSS_AHB_CLK>, > > + <&rpmcc RPM_SMD_XO_CLK_SRC>; > > + clock-names = "iface", "ref"; > > + > > + status = "disabled"; > > + }; > > + }; > > + > > dispcc: clock-controller@5f00000 { > > compatible = "qcom,sm6125-dispcc"; > > reg = <0x05f00000 0x20000>; > > clocks = <&rpmcc RPM_SMD_XO_CLK_SRC>, > > + <&gcc GCC_DISP_GPLL0_DIV_CLK_SRC>, > > + <&mdss_dsi0_phy 0>, > > + <&mdss_dsi0_phy 1>, > > <0>, > > <0>, > > - <0>, > > - <0>, > > - <0>, > > - <&gcc GCC_DISP_GPLL0_DIV_CLK_SRC>; > > + <0>; > > clock-names = "bi_tcxo", > Wrong patch Yup, as said by many folks in many places. It seems the --fixup went to the wrong commit, even though the clock-names were fixup'ed into the right one... Have fixed this for v2. - Marijn > > Konrad > > "gcc_disp_gpll0_div_clk_src", > > "dsi0_phy_pll_out_byteclk", > >