From patchwork Wed Dec 14 13:11:16 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AngeloGioacchino Del Regno X-Patchwork-Id: 33200 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:e747:0:0:0:0:0 with SMTP id c7csp213502wrn; Wed, 14 Dec 2022 05:19:45 -0800 (PST) X-Google-Smtp-Source: AA0mqf5ZkX0Um/od5bZ/TjsJ4Ej4RrGXtjwR3VqcVajQtkjMdjFgt+FkC5ELgVo/87qRj9X4apiS X-Received: by 2002:a05:6402:1017:b0:462:273b:5a7f with SMTP id c23-20020a056402101700b00462273b5a7fmr22290149edu.18.1671023985529; Wed, 14 Dec 2022 05:19:45 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671023985; cv=none; d=google.com; s=arc-20160816; b=V7M+GMCs20CrIHjxla2IVwLhlXWaZWhHLuNBmDqugFhqr3wV+wD+Lw4RzFB6uCxn30 3Y+t9xYe2Gz9f5XXTaV+f4LyuMPOk1EoPQLRV0MWeQnqC9Ij+EftxEp3l5xvsr+RTo6R pFlH5uReAq93U4JlBIpcGVNAfF5P4RB4X8WQ9s0D+ppDGI1bNaiFIU//OHu0gYeKr7Yw nLkkFhqhFi1t4qMFuslQEsdPX/q/OGiReQgoyRRo5ZdlIlIfHsw3JdOLesvgiengq2LW UkuTaF1rFhtusrrPvYUxC8Qypvw+gcqIlN0q4Df17d8QeK8bvT0Y1rCCiRLlF7xWAhrL Gc2w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=Dh7tvnksQzJOEuHee/xqoDVN5a2mxxTRWQXFqCxdnSo=; b=maMV0qy+oiLjIrd/WKxDpfZqw+QsGGGzYKeJnkJJd6T9w3U/sMBos6awiZVfnk1HEl 9QW8wFny7OVTFNdyHPqUgo/LVzubmX/fq9N4mrFvnBP/8wp+39tPTlB6oPls+evydhrC 5mP3bGXNz3b+VP/h2l8FnFc1oMZ4XUDqcnqQIKO2qHog2VNwMzr5dctE/+Ht9GKFqUCm jjnme728YI66XaFvXdACgEyCbLjYiMsdBqNhvmgcZ1y3pobd/8jfugkpiZ5LJqZLuv4Y BPEhdY4IDG97OVEyB86MOwE0GAIEi/sOYiycxfntIpNVUhdaFrWWwWIjverILDxBNww8 DiQA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=BFkQpN0S; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id s18-20020a508d12000000b00469047efecbsi11238244eds.62.2022.12.14.05.19.21; Wed, 14 Dec 2022 05:19:45 -0800 (PST) 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; dkim=pass header.i=@collabora.com header.s=mail header.b=BFkQpN0S; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238577AbiLNNML (ORCPT + 99 others); Wed, 14 Dec 2022 08:12:11 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39908 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238549AbiLNNLr (ORCPT ); Wed, 14 Dec 2022 08:11:47 -0500 Received: from madras.collabora.co.uk (madras.collabora.co.uk [46.235.227.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9438E2181F; Wed, 14 Dec 2022 05:11:33 -0800 (PST) Received: from IcarusMOD.eternityproject.eu (2-237-20-237.ip236.fastwebnet.it [2.237.20.237]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: kholk11) by madras.collabora.co.uk (Postfix) with ESMTPSA id 1D6156602C47; Wed, 14 Dec 2022 13:11:31 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1671023491; bh=43IMkVml1qImsFp1W7CKhzsHSHE25K/j0gQkN5BQMew=; h=From:To:Cc:Subject:Date:From; b=BFkQpN0SqGcGnkvpz31sUKD/KvLZwpXwFibIJ7pudAGxtfMv2894u8cwykZPJtm0S fSum//QYOk3K23y6Eo7gUndJNccZkl+1RRRPBXebSmUHxYspR2x2tzfiZH8Zli23hW 8KBPoLu6X2wFWw76hWBliN4Gtt7Cu/nzLWrQmD4fQo+2NrfDjpIqFNlGHkfCe6ysDJ WhVPyk4DO4pztht9KtRciLt9oT/lSQXfkk15zXaPggfZ4W92AUabMf7GBjCAJn/KLr TRIEFimYkWnE09zHZ8g6RIQb1ARWsUI/w4gaGg7EoUho2OqBDX0ccHL82RtvSxVJSB 5phAas90/aOcg== From: AngeloGioacchino Del Regno To: matthias.bgg@gmail.com Cc: robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, tinghan.shen@mediatek.com, weiyi.lu@mediatek.com, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org, AngeloGioacchino Del Regno Subject: [PATCH 1/2] arm64: dts: mediatek: mt8195: Use P1 clocks for PCIe1 controller Date: Wed, 14 Dec 2022 14:11:16 +0100 Message-Id: <20221214131117.108008-1-angelogioacchino.delregno@collabora.com> X-Mailer: git-send-email 2.38.1 MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1752195646507945637?= X-GMAIL-MSGID: =?utf-8?q?1752195646507945637?= Despite there being some flexibility regarding the P0/P1 connections, especially for TL and PERI, we must use P1 clocks on pcie1 otherwise we'll be dealing with unclocked access. Signed-off-by: AngeloGioacchino Del Regno --- arch/arm64/boot/dts/mediatek/mt8195.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm64/boot/dts/mediatek/mt8195.dtsi b/arch/arm64/boot/dts/mediatek/mt8195.dtsi index 5d31536f4c48..e61944510b8e 100644 --- a/arch/arm64/boot/dts/mediatek/mt8195.dtsi +++ b/arch/arm64/boot/dts/mediatek/mt8195.dtsi @@ -1258,9 +1258,9 @@ pcie1: pcie@112f8000 { clocks = <&infracfg_ao CLK_INFRA_AO_PCIE_PL_P_250M_P1>, <&clk26m>, - <&infracfg_ao CLK_INFRA_AO_PCIE_TL_96M>, + <&infracfg_ao CLK_INFRA_AO_PCIE_P1_TL_96M>, <&clk26m>, - <&infracfg_ao CLK_INFRA_AO_PCIE_PERI_26M>, + <&infracfg_ao CLK_INFRA_AO_PCIE_P1_PERI_26M>, /* Designer has connect pcie1 with peri_mem_p0 clock */ <&pericfg_ao CLK_PERI_AO_PCIE_P0_MEM>; clock-names = "pl_250m", "tl_26m", "tl_96m", From patchwork Wed Dec 14 13:11:17 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AngeloGioacchino Del Regno X-Patchwork-Id: 33199 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:e747:0:0:0:0:0 with SMTP id c7csp213467wrn; Wed, 14 Dec 2022 05:19:40 -0800 (PST) X-Google-Smtp-Source: AA0mqf7cGJcwKVPTpiSnYhdWY3y7QQRHd+pQUmo6JjgkRci0o0shSMIft9Cp0r2vJIjWc/hjgGYB X-Received: by 2002:a17:907:595:b0:7c0:f4f8:582a with SMTP id vw21-20020a170907059500b007c0f4f8582amr17206464ejb.52.1671023979947; Wed, 14 Dec 2022 05:19:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671023979; cv=none; d=google.com; s=arc-20160816; b=bya+Jk/zrAm7v761AZGBGTkq/sGMbf7+qZi8fT7wPXi8LNdEDrx/tAaMaZ5M8ug7fR CM+/FXVaIbpEKWn8sPjb0R52wM0evZR3/eHv0PiPMBLOLNQxpsiRvjWBq9VuDbD7Cyts 5AD6xW+xlkTl8Ez19dbfGlE2mA4+yvDnlqNtaYBCN3GLOFVQA59n02MoOcx9+cwzduob sdn0lzqMClRMr3oNWUnI56S2W8nlPkbwiP9sGehZVjCGSRHrODhI39sHg5+hBperhE/R hUgZZ2GUXyUBFQCkiEceiE98UdmEc5n65Sm9xBFpE17+wjYC4fztkAMAtXiwSyQ7ePwm 31qw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=8Y+sJr2DzYMq8h7VXUpDgrGooEfhLJbI8F5DbSbmHDY=; b=DX5KExo55L7Z4Wzrn1qiinDWb+dj5nuE5IP9XHgiM3MehaxIfL+w01va11lV9BmUEU 1GJ5W+NU7BbDyLip0qd08Vf8RmjLy7FVQ4phjtSBNP90bYA9YGL7lwjXaO8QIpAn5qXn 8tIi97gfD0XCVtZ7jqeOxol78VjPIyph1jPpkU7gY7BCn3Z0iBlJoB7l7IwNdWeol+nS zGKkuu9wYzW5YY92bUISWeILcpukv9zuE2yczshsSDglioYURpyiMdQgvQSZIyFGmE8E jV7t6deaKOiRZVse6qZ9CcWxbR2w9vFFqlMKq9AsnPn6MH6dHkqEE44vG+HQtXIZzTR0 B3Zg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=b8nGE4bf; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id xg5-20020a170907320500b007c0a9cff536si10829741ejb.510.2022.12.14.05.19.15; Wed, 14 Dec 2022 05:19:39 -0800 (PST) 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; dkim=pass header.i=@collabora.com header.s=mail header.b=b8nGE4bf; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238521AbiLNNMJ (ORCPT + 99 others); Wed, 14 Dec 2022 08:12:09 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40264 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238577AbiLNNLr (ORCPT ); Wed, 14 Dec 2022 08:11:47 -0500 Received: from madras.collabora.co.uk (madras.collabora.co.uk [IPv6:2a00:1098:0:82:1000:25:2eeb:e5ab]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 946CF21E18; Wed, 14 Dec 2022 05:11:33 -0800 (PST) Received: from IcarusMOD.eternityproject.eu (2-237-20-237.ip236.fastwebnet.it [2.237.20.237]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: kholk11) by madras.collabora.co.uk (Postfix) with ESMTPSA id C72106602C48; Wed, 14 Dec 2022 13:11:31 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1671023492; bh=QTKESx542e6FJD6rGcbgjaPumHHCtgmxbjfUwumu8oc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=b8nGE4bfc9ypr98vsy9szzGgqpXVzea10EFDG0sAJTxgBqgCNstIuI+X378rFF+d6 YDMmawKSys7soiqcRZpDkV+lbIsV80MR15a1X2rYiM2qTprBHZeedZyEOSBLmtcLCv 7Uhcc3vo0eT4H8DpN+5ejl/Wkeh9+2U0sbso+NpNBTIiy8/LJrf+bTAKVm0J6fikp2 mbeHCuCUp/tHNwWh6F5vwoybswV0YkKyIO865xsWv8xpIS4tWgMG/CjjhqN1miS6AB XNIQDSVIZMHN7GdCGTQ6TKsatkebbqYmAaosZBHGn8skt4HWKvBajJvuZ3j7o4G3OY xvxYmvUixEB4A== From: AngeloGioacchino Del Regno To: matthias.bgg@gmail.com Cc: robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, tinghan.shen@mediatek.com, weiyi.lu@mediatek.com, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org, AngeloGioacchino Del Regno Subject: [PATCH 2/2] arm64: dts: mediatek: mt8195: Add power domain to U3PHY1 T-PHY Date: Wed, 14 Dec 2022 14:11:17 +0100 Message-Id: <20221214131117.108008-2-angelogioacchino.delregno@collabora.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221214131117.108008-1-angelogioacchino.delregno@collabora.com> References: <20221214131117.108008-1-angelogioacchino.delregno@collabora.com> MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1752195640713685683?= X-GMAIL-MSGID: =?utf-8?q?1752195640713685683?= Assign power domain to the U3PHY1 T-PHY in otder to keep this PHY alive after unused PD shutdown and to be able to completely cut and restore power to it, for example, to save some power during system suspend/sleep. Fixes: 2b515194bf0c ("arm64: dts: mt8195: Add power domains controller") Signed-off-by: AngeloGioacchino Del Regno --- arch/arm64/boot/dts/mediatek/mt8195.dtsi | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm64/boot/dts/mediatek/mt8195.dtsi b/arch/arm64/boot/dts/mediatek/mt8195.dtsi index e61944510b8e..131945c44dcc 100644 --- a/arch/arm64/boot/dts/mediatek/mt8195.dtsi +++ b/arch/arm64/boot/dts/mediatek/mt8195.dtsi @@ -1549,6 +1549,7 @@ u3phy1: t-phy@11e30000 { #address-cells = <1>; #size-cells = <1>; ranges = <0 0 0x11e30000 0xe00>; + power-domains = <&spm MT8195_POWER_DOMAIN_SSUSB_PCIE_PHY>; status = "disabled"; u2port1: usb-phy@0 {