From patchwork Mon Feb 15 13:50:26 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Leo Yan X-Patchwork-Id: 61934 Delivered-To: patch@linaro.org Received: by 10.112.43.199 with SMTP id y7csp1080339lbl; Mon, 15 Feb 2016 05:51:36 -0800 (PST) X-Received: by 10.98.18.15 with SMTP id a15mr23551295pfj.145.1455544296600; Mon, 15 Feb 2016 05:51:36 -0800 (PST) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id zd6si43538178pac.222.2016.02.15.05.51.36; Mon, 15 Feb 2016 05:51:36 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dkim=pass header.i=@linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753435AbcBONvb (ORCPT + 30 others); Mon, 15 Feb 2016 08:51:31 -0500 Received: from mail-pf0-f176.google.com ([209.85.192.176]:36154 "EHLO mail-pf0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753419AbcBONvZ (ORCPT ); Mon, 15 Feb 2016 08:51:25 -0500 Received: by mail-pf0-f176.google.com with SMTP id e127so87968302pfe.3 for ; Mon, 15 Feb 2016 05:51:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:subject:date:message-id:in-reply-to:references; bh=M/Rci5kt6J1gEqCLW59OjQr5VJaX3QdXMXQcFiucWz4=; b=gEsXuDyAZHPhW5ACLFTuEnoxkD0b0zVbvQEi1UBV0W7VKlLA9Mu3ljnY5Yg5MeRzLj s9WHOIcohM4teu1cQkRSrVFhzkhrLabA7G1Khvpy58bb/nf//wlQ3Z3NRQTDdE8s6h7O GVzpBv6BrAOTyojTBsnNJEsfRgkUPcu3kc9no= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references; bh=M/Rci5kt6J1gEqCLW59OjQr5VJaX3QdXMXQcFiucWz4=; b=O1cv1J5uf3+igXRDJX7dJRXg3qTvwvbdCp+J6GwGx1HasE5M5pnbQrUAcIkjvOjKqm luXeXyR9OYFRk3BQih1/VBg+KduKkt9lpPTZouAy1LU2jpw2y2sOiXxa6SpkoCC8TARU BxwyK8gXffoXmUCBm26dOZkr9Mh4UzSfMSHd6av15zFoy08TQ4UHfkG9nirJVSONcH/V Od11Q5I8Pdzg+7gPaYP5nVE6/GNC8LF7b4T5jwMrNTSYPjbq+PhWOOHHLAbSl/D2OIRr x8u3HLmAWMaQ4dm2BUq0V9bnZo5+iku4vGdMQReDguRYSPkIVuP/I0f66YxSUEmnOh8o ZK1w== X-Gm-Message-State: AG10YOSmYdAN0RbOkKueo1L+tFgLYtJqu+sFCYt2I1tCZHWO5Z7PM2Eeewx9KJeMdVWirgGa X-Received: by 10.98.16.12 with SMTP id y12mr23674997pfi.6.1455544284811; Mon, 15 Feb 2016 05:51:24 -0800 (PST) Received: from localhost.localdomain (v17.blockcn.net. [192.241.236.26]) by smtp.gmail.com with ESMTPSA id cf6sm38929900pad.41.2016.02.15.05.51.17 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 15 Feb 2016 05:51:23 -0800 (PST) From: Leo Yan To: Rob Herring , Pawel Moll , Mark Rutland , Ian Campbell , Kumar Gala , Catalin Marinas , Will Deacon , Jassi Brar , Leo Yan , Tyler Baker , Arnd Bergmann , Sudeep Holla , Bintian Wang , Chen Feng , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Wei Xu Subject: [PATCH v7 RESEND 4/4] arm64: dts: add Hi6220's stub clock node Date: Mon, 15 Feb 2016 21:50:26 +0800 Message-Id: <1455544226-10094-5-git-send-email-leo.yan@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1455544226-10094-1-git-send-email-leo.yan@linaro.org> References: <1455544226-10094-1-git-send-email-leo.yan@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Enable SRAM node and stub clock node for Hi6220, which uses mailbox channel 1 for CPU's frequency change. Furthermore, add the CPU clock phandle in CPU's node and using operating-points-v2 to register operating points. So can be used by cpufreq-dt driver. Signed-off-by: Leo Yan --- arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 56 +++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) -- 1.9.1 diff --git a/arch/arm64/boot/dts/hisilicon/hi6220.dtsi b/arch/arm64/boot/dts/hisilicon/hi6220.dtsi index 23c79e1..f588be9 100644 --- a/arch/arm64/boot/dts/hisilicon/hi6220.dtsi +++ b/arch/arm64/boot/dts/hisilicon/hi6220.dtsi @@ -81,6 +81,11 @@ device_type = "cpu"; reg = <0x0 0x0>; enable-method = "psci"; + clocks = <&stub_clock 0>; + operating-points-v2 = <&cpu_opp_table>; + cooling-min-level = <4>; + cooling-max-level = <0>; + #cooling-cells = <2>; /* min followed by max */ cpu-idle-states = <&CPU_SLEEP &CLUSTER_SLEEP>; }; @@ -89,6 +94,7 @@ device_type = "cpu"; reg = <0x0 0x1>; enable-method = "psci"; + operating-points-v2 = <&cpu_opp_table>; cpu-idle-states = <&CPU_SLEEP &CLUSTER_SLEEP>; }; @@ -97,6 +103,7 @@ device_type = "cpu"; reg = <0x0 0x2>; enable-method = "psci"; + operating-points-v2 = <&cpu_opp_table>; cpu-idle-states = <&CPU_SLEEP &CLUSTER_SLEEP>; }; @@ -105,6 +112,7 @@ device_type = "cpu"; reg = <0x0 0x3>; enable-method = "psci"; + operating-points-v2 = <&cpu_opp_table>; cpu-idle-states = <&CPU_SLEEP &CLUSTER_SLEEP>; }; @@ -113,6 +121,7 @@ device_type = "cpu"; reg = <0x0 0x100>; enable-method = "psci"; + operating-points-v2 = <&cpu_opp_table>; cpu-idle-states = <&CPU_SLEEP &CLUSTER_SLEEP>; }; @@ -121,6 +130,7 @@ device_type = "cpu"; reg = <0x0 0x101>; enable-method = "psci"; + operating-points-v2 = <&cpu_opp_table>; cpu-idle-states = <&CPU_SLEEP &CLUSTER_SLEEP>; }; @@ -129,6 +139,7 @@ device_type = "cpu"; reg = <0x0 0x102>; enable-method = "psci"; + operating-points-v2 = <&cpu_opp_table>; cpu-idle-states = <&CPU_SLEEP &CLUSTER_SLEEP>; }; @@ -137,10 +148,42 @@ device_type = "cpu"; reg = <0x0 0x103>; enable-method = "psci"; + operating-points-v2 = <&cpu_opp_table>; cpu-idle-states = <&CPU_SLEEP &CLUSTER_SLEEP>; }; }; + cpu_opp_table: cpu_opp_table { + compatible = "operating-points-v2"; + opp-shared; + + opp00 { + opp-hz = /bits/ 64 <208000000>; + opp-microvolt = <1040000>; + clock-latency-ns = <500000>; + }; + opp01 { + opp-hz = /bits/ 64 <432000000>; + opp-microvolt = <1040000>; + clock-latency-ns = <500000>; + }; + opp02 { + opp-hz = /bits/ 64 <729000000>; + opp-microvolt = <1090000>; + clock-latency-ns = <500000>; + }; + opp03 { + opp-hz = /bits/ 64 <960000000>; + opp-microvolt = <1180000>; + clock-latency-ns = <500000>; + }; + opp04 { + opp-hz = /bits/ 64 <1200000000>; + opp-microvolt = <1330000>; + clock-latency-ns = <500000>; + }; + }; + gic: interrupt-controller@f6801000 { compatible = "arm,gic-400"; reg = <0x0 0xf6801000 0 0x1000>, /* GICD */ @@ -168,6 +211,11 @@ #size-cells = <2>; ranges; + sram: sram@fff80000 { + compatible = "hisilicon,hi6220-sramctrl", "syscon"; + reg = <0x0 0xfff80000 0x0 0x12000>; + }; + ao_ctrl: ao_ctrl@f7800000 { compatible = "hisilicon,hi6220-aoctrl", "syscon"; reg = <0x0 0xf7800000 0x0 0x2000>; @@ -193,6 +241,14 @@ #clock-cells = <1>; }; + stub_clock: stub_clock { + compatible = "hisilicon,hi6220-stub-clk"; + hisilicon,hi6220-clk-sram = <&sram>; + #clock-cells = <1>; + mbox-names = "mbox-tx"; + mboxes = <&mailbox 1 0 11>; + }; + uart0: uart@f8015000 { /* console */ compatible = "arm,pl011", "arm,primecell"; reg = <0x0 0xf8015000 0x0 0x1000>;