From patchwork Fri Mar 11 17:23:52 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Vasut X-Patchwork-Id: 12778428 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6E8B9C433FE for ; Fri, 11 Mar 2022 17:25:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=6wJL7qRi9TKols33OQCmurkHk/3Jb7jjJFlwDumMWxU=; b=n/s7qFbH8FAlYl H6BezDIlvEbwv2sieZw80VhKBUQ+bR1ndjcgNeeBjQ5iPiB1WwPhIcWLRXVNLK8njRXKShSzIvLP4 ngGrrYnyMHH/G+/fFC/zobhSXbGH/O6en0U982DAfTJFHRHTKpnwZLKkAjLK3iG9lJW0oP7BNXLlY c4e0/Uz8sjIrnV+H92Bcj99vIGWyLCADb9oDYCTJh9KQ6XH/IUw7eC6Mrf13TAI31tZX1m/PQvGH3 TSVU9RC5BRGstDouK4hK9CzKl9zhfyh0qRFTqfz3kIvxKQQuIS53zP5owhvX9ntXdDLSPEh3V3YJ5 EJ93OdbQg9eYKIWwpecg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nSj03-00HUSl-O1; Fri, 11 Mar 2022 17:24:23 +0000 Received: from phobos.denx.de ([85.214.62.61]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nSizr-00HUQa-3e for linux-arm-kernel@lists.infradead.org; Fri, 11 Mar 2022 17:24:12 +0000 Received: from tr.lan (ip-89-176-112-137.net.upcbroadband.cz [89.176.112.137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: marex@denx.de) by phobos.denx.de (Postfix) with ESMTPSA id 5F188839E8; Fri, 11 Mar 2022 18:24:07 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1647019447; bh=WkQLHZLnMCnk6APnovMgxIlB5wsEsjt+mJtBotMWzw4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=S5dkRJ0+v/55/npdV+b4moHNLvBJBffjCVps6j06FEG366ATbHNP00ANn8Si7dH00 ceCu5VIvfNMteRFC56tbcPEdACR+U7bGcQNZhBpG2YFRQn89xYQm1zAA0ax+mbV9hu xiDcxETsgt+iZtQ6DoS/lgp+ZVIhLrcEIkhJJpGwv3xW5Ux4F3pW6Q2aAUgQmnBaDT Mu2meu8+NhJt9ddvUM5CYuwJhiRbOQXqMhmr2GmVZAqMwAge+nYilm/nNdtJjqNAL4 lLzIkUCAmI2upBo7L4sfsGGpqw0QoIMjrIHynijvaTUQNbM2ffIoMNoG0ycjnBcqg5 x4q414xIfuR6A== From: Marek Vasut To: linux-arm-kernel@lists.infradead.org Cc: Marek Vasut , Anson Huang , Fabio Estevam , Peng Fan , Shawn Guo , NXP Linux Team Subject: [PATCH 2/2] arm64: dts: imx8mp: Add cpu-freq support Date: Fri, 11 Mar 2022 18:23:52 +0100 Message-Id: <20220311172352.56802-2-marex@denx.de> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220311172352.56802-1-marex@denx.de> References: <20220311172352.56802-1-marex@denx.de> MIME-Version: 1.0 X-Virus-Scanned: clamav-milter 0.103.5 at phobos.denx.de X-Virus-Status: Clean X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220311_092411_343630_7C8217B6 X-CRM114-Status: GOOD ( 10.37 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Add A53 OPP table and cpu regulator to support cpu-freq driver. Signed-off-by: Marek Vasut Cc: Anson Huang Cc: Fabio Estevam Cc: Peng Fan Cc: Shawn Guo Cc: NXP Linux Team To: linux-arm-kernel@lists.infradead.org --- Note: the commit message is partly copied from MX8MN --- arch/arm64/boot/dts/freescale/imx8mp.dtsi | 33 +++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/arch/arm64/boot/dts/freescale/imx8mp.dtsi b/arch/arm64/boot/dts/freescale/imx8mp.dtsi index 077ade2b1b0c4..89f4005beecb2 100644 --- a/arch/arm64/boot/dts/freescale/imx8mp.dtsi +++ b/arch/arm64/boot/dts/freescale/imx8mp.dtsi @@ -60,6 +60,7 @@ A53_0: cpu@0 { next-level-cache = <&A53_L2>; nvmem-cells = <&cpu_speed_grade>; nvmem-cell-names = "speed_grade"; + operating-points-v2 = <&a53_opp_table>; #cooling-cells = <2>; }; @@ -77,6 +78,7 @@ A53_1: cpu@1 { d-cache-line-size = <64>; d-cache-sets = <128>; next-level-cache = <&A53_L2>; + operating-points-v2 = <&a53_opp_table>; #cooling-cells = <2>; }; @@ -94,6 +96,7 @@ A53_2: cpu@2 { d-cache-line-size = <64>; d-cache-sets = <128>; next-level-cache = <&A53_L2>; + operating-points-v2 = <&a53_opp_table>; #cooling-cells = <2>; }; @@ -111,6 +114,7 @@ A53_3: cpu@3 { d-cache-line-size = <64>; d-cache-sets = <128>; next-level-cache = <&A53_L2>; + operating-points-v2 = <&a53_opp_table>; #cooling-cells = <2>; }; @@ -123,6 +127,35 @@ A53_L2: l2-cache0 { }; }; + a53_opp_table: opp-table { + compatible = "operating-points-v2"; + opp-shared; + + opp-1200000000 { + opp-hz = /bits/ 64 <1200000000>; + opp-microvolt = <850000>; + opp-supported-hw = <0x8a0>, <0x7>; + clock-latency-ns = <150000>; + opp-suspend; + }; + + opp-1600000000 { + opp-hz = /bits/ 64 <1600000000>; + opp-microvolt = <950000>; + opp-supported-hw = <0xa0>, <0x7>; + clock-latency-ns = <150000>; + opp-suspend; + }; + + opp-1800000000 { + opp-hz = /bits/ 64 <1800000000>; + opp-microvolt = <1000000>; + opp-supported-hw = <0x20>, <0x3>; + clock-latency-ns = <150000>; + opp-suspend; + }; + }; + osc_32k: clock-osc-32k { compatible = "fixed-clock"; #clock-cells = <0>;