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 phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 5E0FBC6FD1D for ; Tue, 21 Mar 2023 03:15:25 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 54D6385CAD; Tue, 21 Mar 2023 04:15:23 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=fail (p=none dis=none) header.from=rock-chips.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Received: by phobos.denx.de (Postfix, from userid 109) id 1451D85C9B; Tue, 21 Mar 2023 04:15:16 +0100 (CET) Received: from mail-m11874.qiye.163.com (mail-m11874.qiye.163.com [115.236.118.74]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 2EC6085C77 for ; Tue, 21 Mar 2023 04:15:04 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=rock-chips.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=kever.yang@rock-chips.com Received: from [172.16.12.93] (unknown [58.22.7.114]) by mail-m11874.qiye.163.com (Hmail) with ESMTPA id D81D23C01CB; Tue, 21 Mar 2023 11:14:50 +0800 (CST) Message-ID: <287d7087-a5cf-628f-2287-abc5d1aba2e6@rock-chips.com> Date: Tue, 21 Mar 2023 11:14:50 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.7.1 Subject: Re: [PATCH v2 2/7] arm: dts: rockchip: rk3288: partial sync grf and pmu nodes Content-Language: en-US To: Johan Jonker Cc: sjg@chromium.org, philipp.tomsich@vrull.eu, w.egorov@phytec.de, hl@rock-chips.com, jernej.skrabec@gmail.com, lukma@denx.de, seanga2@gmail.com, agust@denx.de, u-boot@lists.denx.de References: <99944d4c-25d4-e05c-f5ea-7801f8e1253a@gmail.com> From: Kever Yang In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-HM-Spam-Status: e1kfGhgUHx5ZQUpXWQgPGg8OCBgUHx5ZQUlOS1dZFg8aDwILHllBWSg2Ly tZV1koWUFDSUNOT01LS0k3V1ktWUFJV1kPCRoVCBIfWUFZQk5ITVZJHUwfGE4aT00ZS0NVEwETFh oSFyQUDg9ZV1kYEgtZQVlOQ1VJSVVMVUpKT1lXWRYaDxIVHRRZQVlPS0hVSkpLSEpMVUpLS1VLWQ Y+ X-HM-Sender-Digest: e1kMHhlZQR0aFwgeV1kSHx4VD1lBWUc6MDY6FSo5Ij0RCxA3Hyw0PCMD EyIwFB5VSlVKTUxCSE1DT0JKQ0lIVTMWGhIXVRAeDR4JVQIaFRw7CRQYEFYYExILCFUYFBZFWVdZ EgtZQVlOQ1VJSVVMVUpKT1lXWQgBWUFKS0NJQjcG X-HM-Tid: 0a87022991122eb0kusnd81d23c01cb X-HM-MType: 1 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.8 at phobos.denx.de X-Virus-Status: Clean On 2023/3/16 02:33, Johan Jonker wrote: > In order to better compare the Linux rk3288.dtsi > version 6.3 -rc2 with the U-Boot version partial > sync the grf and pmu nodes. > > Signed-off-by: Johan Jonker > Reviewed-by: Simon Glass > Tested-by: Simon Glass # chromebook-jerry Reviewed-by: Kever Yang Thanks, - Kever > --- > arch/arm/dts/rk3288.dtsi | 269 +++++++++++++++++++++++++-------------- > 1 file changed, 173 insertions(+), 96 deletions(-) > > diff --git a/arch/arm/dts/rk3288.dtsi b/arch/arm/dts/rk3288.dtsi > index 9cfb86f9..f06d1f5b 100644 > --- a/arch/arm/dts/rk3288.dtsi > +++ b/arch/arm/dts/rk3288.dtsi > @@ -1,4 +1,4 @@ > -// SPDX-License-Identifier: GPL-2.0+ > +// SPDX-License-Identifier: (GPL-2.0+ OR MIT) > > #include > #include > @@ -7,13 +7,16 @@ > #include > #include > #include > -#include > -#include "skeleton.dtsi" > +#include > > / { > + #address-cells = <1>; > + #size-cells = <1>; > + > compatible = "rockchip,rk3288"; > > interrupt-parent = <&gic>; > + > aliases { > ethernet0 = &gmac; > i2c0 = &i2c0; > @@ -732,8 +735,128 @@ > }; > > pmu: power-management@ff730000 { > - compatible = "rockchip,rk3288-pmu", "syscon"; > + compatible = "rockchip,rk3288-pmu", "syscon", "simple-mfd"; > reg = <0xff730000 0x100>; > + > + power: power-controller { > + compatible = "rockchip,rk3288-power-controller"; > + #power-domain-cells = <1>; > + #address-cells = <1>; > + #size-cells = <0>; > + > + assigned-clocks = <&cru SCLK_EDP_24M>; > + assigned-clock-parents = <&xin24m>; > + > + /* > + * Note: Although SCLK_* are the working clocks > + * of device without including on the NOC, needed for > + * synchronous reset. > + * > + * The clocks on the which NOC: > + * ACLK_IEP/ACLK_VIP/ACLK_VOP0 are on ACLK_VIO0_NIU. > + * ACLK_ISP/ACLK_VOP1 are on ACLK_VIO1_NIU. > + * ACLK_RGA is on ACLK_RGA_NIU. > + * The others (HCLK_*,PLCK_*) are on HCLK_VIO_NIU. > + * > + * Which clock are device clocks: > + * clocks devices > + * *_IEP IEP:Image Enhancement Processor > + * *_ISP ISP:Image Signal Processing > + * *_VIP VIP:Video Input Processor > + * *_VOP* VOP:Visual Output Processor > + * *_RGA RGA > + * *_EDP* EDP > + * *_LVDS_* LVDS > + * *_HDMI HDMI > + * *_MIPI_* MIPI > + */ > + power-domain@RK3288_PD_VIO { > + reg = ; > + clocks = <&cru ACLK_IEP>, > + <&cru ACLK_ISP>, > + <&cru ACLK_RGA>, > + <&cru ACLK_VIP>, > + <&cru ACLK_VOP0>, > + <&cru ACLK_VOP1>, > + <&cru DCLK_VOP0>, > + <&cru DCLK_VOP1>, > + <&cru HCLK_IEP>, > + <&cru HCLK_ISP>, > + <&cru HCLK_RGA>, > + <&cru HCLK_VIP>, > + <&cru HCLK_VOP0>, > + <&cru HCLK_VOP1>, > + <&cru PCLK_EDP_CTRL>, > + <&cru PCLK_HDMI_CTRL>, > + <&cru PCLK_LVDS_PHY>, > + <&cru PCLK_MIPI_CSI>, > + <&cru PCLK_MIPI_DSI0>, > + <&cru PCLK_MIPI_DSI1>, > + <&cru SCLK_EDP_24M>, > + <&cru SCLK_EDP>, > + <&cru SCLK_ISP_JPE>, > + <&cru SCLK_ISP>, > + <&cru SCLK_RGA>; > + pm_qos = <&qos_vio0_iep>, > + <&qos_vio1_vop>, > + <&qos_vio1_isp_w0>, > + <&qos_vio1_isp_w1>, > + <&qos_vio0_vop>, > + <&qos_vio0_vip>, > + <&qos_vio2_rga_r>, > + <&qos_vio2_rga_w>, > + <&qos_vio1_isp_r>; > + #power-domain-cells = <0>; > + }; > + > + /* > + * Note: The following 3 are HEVC(H.265) clocks, > + * and on the ACLK_HEVC_NIU (NOC). > + */ > + power-domain@RK3288_PD_HEVC { > + reg = ; > + clocks = <&cru ACLK_HEVC>, > + <&cru SCLK_HEVC_CABAC>, > + <&cru SCLK_HEVC_CORE>; > + pm_qos = <&qos_hevc_r>, > + <&qos_hevc_w>; > + #power-domain-cells = <0>; > + }; > + > + /* > + * Note: ACLK_VCODEC/HCLK_VCODEC are VCODEC > + * (video endecoder & decoder) clocks that on the > + * ACLK_VCODEC_NIU and HCLK_VCODEC_NIU (NOC). > + */ > + power-domain@RK3288_PD_VIDEO { > + reg = ; > + clocks = <&cru ACLK_VCODEC>, > + <&cru HCLK_VCODEC>; > + pm_qos = <&qos_video>; > + #power-domain-cells = <0>; > + }; > + > + /* > + * Note: ACLK_GPU is the GPU clock, > + * and on the ACLK_GPU_NIU (NOC). > + */ > + power-domain@RK3288_PD_GPU { > + reg = ; > + clocks = <&cru ACLK_GPU>; > + pm_qos = <&qos_gpu_r>, > + <&qos_gpu_w>; > + #power-domain-cells = <0>; > + }; > + }; > + > + reboot-mode { > + compatible = "syscon-reboot-mode"; > + offset = <0x94>; > + mode-normal = ; > + mode-recovery = ; > + mode-bootloader = ; > + mode-loader = ; > + }; > }; > > sgrf: syscon@ff740000 { > @@ -760,13 +883,58 @@ > }; > > grf: syscon@ff770000 { > - compatible = "rockchip,rk3288-grf", "syscon"; > + compatible = "rockchip,rk3288-grf", "syscon", "simple-mfd"; > reg = <0xff770000 0x1000>; > > + edp_phy: edp-phy { > + compatible = "rockchip,rk3288-dp-phy"; > + clocks = <&cru SCLK_EDP_24M>; > + clock-names = "24m"; > + #phy-cells = <0>; > + status = "disabled"; > + }; > + > io_domains: io-domains { > compatible = "rockchip,rk3288-io-voltage-domain"; > status = "disabled"; > }; > + > + usbphy: usbphy { > + compatible = "rockchip,rk3288-usb-phy"; > + #address-cells = <1>; > + #size-cells = <0>; > + status = "disabled"; > + > + usbphy0: usb-phy@320 { > + #phy-cells = <0>; > + reg = <0x320>; > + clocks = <&cru SCLK_OTGPHY0>; > + clock-names = "phyclk"; > + #clock-cells = <0>; > + resets = <&cru SRST_USBOTG_PHY>; > + reset-names = "phy-reset"; > + }; > + > + usbphy1: usb-phy@334 { > + #phy-cells = <0>; > + reg = <0x334>; > + clocks = <&cru SCLK_OTGPHY1>; > + clock-names = "phyclk"; > + #clock-cells = <0>; > + resets = <&cru SRST_USBHOST0_PHY>; > + reset-names = "phy-reset"; > + }; > + > + usbphy2: usb-phy@348 { > + #phy-cells = <0>; > + reg = <0x348>; > + clocks = <&cru SCLK_OTGPHY2>; > + clock-names = "phyclk"; > + #clock-cells = <0>; > + resets = <&cru SRST_USBHOST1_PHY>; > + reset-names = "phy-reset"; > + }; > + }; > }; > > wdt: watchdog@ff800000 { > @@ -1246,39 +1414,6 @@ > interrupts = ; > }; > > - cpuidle: cpuidle { > - compatible = "rockchip,rk3288-cpuidle"; > - }; > - > - usbphy: phy { > - compatible = "rockchip,rk3288-usb-phy"; > - rockchip,grf = <&grf>; > - #address-cells = <1>; > - #size-cells = <0>; > - status = "disabled"; > - > - usbphy0: usb-phy0 { > - #phy-cells = <0>; > - reg = <0x320>; > - clocks = <&cru SCLK_OTGPHY0>; > - clock-names = "phyclk"; > - }; > - > - usbphy1: usb-phy1 { > - #phy-cells = <0>; > - reg = <0x334>; > - clocks = <&cru SCLK_OTGPHY1>; > - clock-names = "phyclk"; > - }; > - > - usbphy2: usb-phy2 { > - #phy-cells = <0>; > - reg = <0x348>; > - clocks = <&cru SCLK_OTGPHY2>; > - clock-names = "phyclk"; > - }; > - }; > - > pinctrl: pinctrl { > compatible = "rockchip,rk3288-pinctrl"; > rockchip,grf = <&grf>; > @@ -1865,62 +2000,4 @@ > }; > }; > }; > - > - power: power-controller { > - compatible = "rockchip,rk3288-power-controller"; > - #power-domain-cells = <1>; > - rockchip,pmu = <&pmu>; > - #address-cells = <1>; > - #size-cells = <0>; > - > - pd_gpu { > - reg = ; > - clocks = <&cru ACLK_GPU>; > - }; > - > - pd_hevc { > - reg = ; > - clocks = <&cru ACLK_HEVC>, > - <&cru SCLK_HEVC_CABAC>, > - <&cru SCLK_HEVC_CORE>, > - <&cru HCLK_HEVC>; > - }; > - > - pd_vio { > - reg = ; > - clocks = <&cru ACLK_IEP>, > - <&cru ACLK_ISP>, > - <&cru ACLK_RGA>, > - <&cru ACLK_VIP>, > - <&cru ACLK_VOP0>, > - <&cru ACLK_VOP1>, > - <&cru DCLK_VOP0>, > - <&cru DCLK_VOP1>, > - <&cru HCLK_IEP>, > - <&cru HCLK_ISP>, > - <&cru HCLK_RGA>, > - <&cru HCLK_VIP>, > - <&cru HCLK_VOP0>, > - <&cru HCLK_VOP1>, > - <&cru PCLK_EDP_CTRL>, > - <&cru PCLK_HDMI_CTRL>, > - <&cru PCLK_LVDS_PHY>, > - <&cru PCLK_MIPI_CSI>, > - <&cru PCLK_MIPI_DSI0>, > - <&cru PCLK_MIPI_DSI1>, > - <&cru SCLK_EDP_24M>, > - <&cru SCLK_EDP>, > - <&cru SCLK_HDMI_CEC>, > - <&cru SCLK_HDMI_HDCP>, > - <&cru SCLK_ISP_JPE>, > - <&cru SCLK_ISP>, > - <&cru SCLK_RGA>; > - }; > - > - pd_video { > - reg = ; > - clocks = <&cru ACLK_VCODEC>, > - <&cru HCLK_VCODEC>; > - }; > - }; > }; > -- > 2.20.1 >