Received: by 10.192.165.156 with SMTP id m28csp1827586imm; Thu, 12 Apr 2018 04:19:45 -0700 (PDT) X-Google-Smtp-Source: AIpwx4/ZL3WlgllDkOBfZBZ1pUTfwt9KhfWfjGK6TY+fTXgk+PGyyBEubRgJWFwf+1n6HfItSh+B X-Received: by 10.98.17.210 with SMTP id 79mr7310115pfr.65.1523531985328; Thu, 12 Apr 2018 04:19:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1523531985; cv=none; d=google.com; s=arc-20160816; b=eXWUIrD8eWEc5bti7ztNiwUAPmyWrPF/u908WuT+kEKqvaWhhy/HgAruFD2p3NqUED SwhNRPpjg9H9CrNgsMMUvuuh6mR4DKqeu+SEpiKYqVf/ulPxypmqCtEgQv3c34MG7ThL 7E//UHBou+e7YkAf16mLqjKnf8MUoiydbFCvbFqipg4OEImSduN1/ZrVhv4gNdWU9CLF ZU8vril0au0xvpxg9WKGRUjFAoYIcB/ZKKQQ4ts6eUl4zBfyg3FsfqqE0w3YNckYCfmc bxGUXQlTGL+8GnsVhrUMrJsubhWZI87bc8Fkl9ZmWqmPWlPItiHwMFFkhfBvWASViiDt TXMQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=IIHiCEQkHG1b/nIuCHEJ9c4Cvzg0QwX/XRz1/Yv43Ow=; b=R/Oq8UZzbEhL8eiJV10DEPn+OKFz3GQMqlytXCS/dnicqiE6nK9b8T14MtUlv4ocLj w3Weo8etwa+ZjFnJNpVSxhkstxvYVy9XcZ4NMLUYsEClA3ZiHCPuVeMjQj4ZhxT2K+64 Ag8DvamuzK27AQswN3fk5hAJfM8T0m3Pjcy45xRN+zeNOIU9B/J/nCRLFB97PsMf6W99 CXH3uraI9ophHGXtSdzLAcwEj86yyhrMEb4ngiwavgech01EfIRTgaUb3ZWcUtpTTY3n I7AMfgYjmyKrJGPbiXXUKvmpctHWInIR+k27GR2AKuB8JcMlhhC63sLBAYGka9pq4v+M bWiA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Ip2YcZ4b; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k62si2137568pgc.453.2018.04.12.04.19.08; Thu, 12 Apr 2018 04:19:45 -0700 (PDT) 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; dkim=pass header.i=@linaro.org header.s=google header.b=Ip2YcZ4b; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752866AbeDLLPx (ORCPT + 99 others); Thu, 12 Apr 2018 07:15:53 -0400 Received: from mail-lf0-f68.google.com ([209.85.215.68]:35648 "EHLO mail-lf0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752821AbeDLLPZ (ORCPT ); Thu, 12 Apr 2018 07:15:25 -0400 Received: by mail-lf0-f68.google.com with SMTP id b189-v6so7139223lfe.2 for ; Thu, 12 Apr 2018 04:15:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=IIHiCEQkHG1b/nIuCHEJ9c4Cvzg0QwX/XRz1/Yv43Ow=; b=Ip2YcZ4baT7qIUsN3y5QR0iqBIc7WSISvJ2BuTL6zkjcNl1PJr2JXhTXxByHsHgKoA 3J3dCCgHYsWa45OHiNAbt3zf9el5yuaBVI1YX6a5ALLDDdhRWxlNBWuKu/mukgEKsh7o +rQOjas24jYwavIa+vvsrZu1sz+cWBsU9j+tM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=IIHiCEQkHG1b/nIuCHEJ9c4Cvzg0QwX/XRz1/Yv43Ow=; b=m2IoGNJrCFs4clhu0oxn/pE8vYCRVGE8E6zDwjC9Pb1aKaQ/DGWkIUsvltAuj33mdb Nq4A5EYzt1XgwVH6l7Wr1hoCSebG9ufn/ZxNzSLpfyMWjl18bx3nsVMFC2VkTvL+8kQs I0n3BOrdpqpPxZLrzHqUdSJrkRcEzWUkvIZUyZ0dwKkKQ4lZXutGK55ewn/DpICWlVVf MnGJN2q95SMvtSnZlug38NoBHvnMvQSAa1zU4xfVyhDHqMlhS9DsMOXojDiayoWJ1CgC 2QGgQbXX8Xcsh6SHqC6kHjlEEwldZ6t/bVo5/pbpQnX+SQn9OCQuPO3+o1pQft72UWLY fdsw== X-Gm-Message-State: ALQs6tBeHDENwRjua9zrhgstEm2gUfoLIvCPIygF4lHGqxfmv5nQvRIa Y+Rfw6neS8ow5XYFwYIVCQWaSw== X-Received: by 2002:a19:6a16:: with SMTP id u22-v6mr5000049lfu.123.1523531724219; Thu, 12 Apr 2018 04:15:24 -0700 (PDT) Received: from localhost.localdomain (h-158-174-22-210.NA.cust.bahnhof.se. [158.174.22.210]) by smtp.gmail.com with ESMTPSA id r29sm543187lje.72.2018.04.12.04.15.22 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 12 Apr 2018 04:15:23 -0700 (PDT) From: Ulf Hansson To: "Rafael J . Wysocki" , Sudeep Holla , Lorenzo Pieralisi , Mark Rutland , linux-pm@vger.kernel.org Cc: Kevin Hilman , Lina Iyer , Lina Iyer , Ulf Hansson , Rob Herring , Daniel Lezcano , Thomas Gleixner , Vincent Guittot , Stephen Boyd , Juri Lelli , Geert Uytterhoeven , linux-arm-kernel@lists.infradead.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, Andy Gross , David Brown Subject: [PATCH v7 26/26] arm64: dts: Convert to the hierarchical CPU topology layout for MSM8916 Date: Thu, 12 Apr 2018 13:14:31 +0200 Message-Id: <1523531671-27491-27-git-send-email-ulf.hansson@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1523531671-27491-1-git-send-email-ulf.hansson@linaro.org> References: <1523531671-27491-1-git-send-email-ulf.hansson@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Lina Iyer In the hierarchical layout, we are creating power domains around each CPU and describes the idle states for them inside the power domain provider node. Note that, the CPU's idle states still needs to be compatible with "arm,idle-state". Furthermore, represent the CPU cluster as a separate master power domain, powering the CPU's power domains. The cluster node, contains the idle states for the cluster and each idle state needs to be compatible with the "domain-idle-state". If the running platform is using a PSCI FW that supports the OS initiated CPU suspend mode, which likely should be the case unless the PSCI FW is very old, this change makes the PSCI driver to enable it. Cc: Andy Gross Cc: David Brown Cc: Lina Iyer Signed-off-by: Lina Iyer Co-developed-by: Ulf Hansson Signed-off-by: Ulf Hansson --- arch/arm64/boot/dts/qcom/msm8916.dtsi | 53 ++++++++++++++++++++++++++++++++--- 1 file changed, 49 insertions(+), 4 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/msm8916.dtsi b/arch/arm64/boot/dts/qcom/msm8916.dtsi index 66b318e..aff4b91 100644 --- a/arch/arm64/boot/dts/qcom/msm8916.dtsi +++ b/arch/arm64/boot/dts/qcom/msm8916.dtsi @@ -113,10 +113,10 @@ reg = <0x0>; next-level-cache = <&L2_0>; enable-method = "psci"; - cpu-idle-states = <&CPU_SPC>; clocks = <&apcs 0>; operating-points-v2 = <&cpu_opp_table>; #cooling-cells = <2>; + power-domains = <&CPU_PD0>; }; CPU1: cpu@1 { @@ -125,10 +125,10 @@ reg = <0x1>; next-level-cache = <&L2_0>; enable-method = "psci"; - cpu-idle-states = <&CPU_SPC>; clocks = <&apcs 0>; operating-points-v2 = <&cpu_opp_table>; #cooling-cells = <2>; + power-domains = <&CPU_PD1>; }; CPU2: cpu@2 { @@ -137,10 +137,10 @@ reg = <0x2>; next-level-cache = <&L2_0>; enable-method = "psci"; - cpu-idle-states = <&CPU_SPC>; clocks = <&apcs 0>; operating-points-v2 = <&cpu_opp_table>; #cooling-cells = <2>; + power-domains = <&CPU_PD2>; }; CPU3: cpu@3 { @@ -149,10 +149,10 @@ reg = <0x3>; next-level-cache = <&L2_0>; enable-method = "psci"; - cpu-idle-states = <&CPU_SPC>; clocks = <&apcs 0>; operating-points-v2 = <&cpu_opp_table>; #cooling-cells = <2>; + power-domains = <&CPU_PD3>; }; L2_0: l2-cache { @@ -169,12 +169,57 @@ min-residency-us = <2000>; local-timer-stop; }; + + CLUSTER_RET: cluster-retention { + compatible = "domain-idle-state"; + arm,psci-suspend-param = <0x1000010>; + entry-latency-us = <500>; + exit-latency-us = <500>; + min-residency-us = <2000>; + }; + + CLUSTER_PWRDN: cluster-gdhs { + compatible = "domain-idle-state"; + arm,psci-suspend-param = <0x1000030>; + entry-latency-us = <2000>; + exit-latency-us = <2000>; + min-residency-us = <6000>; + }; }; }; psci { compatible = "arm,psci-1.0"; method = "smc"; + + CPU_PD0: cpu-pd0 { + #power-domain-cells = <0>; + power-domains = <&CLUSTER_PD>; + domain-idle-states = <&CPU_SPC>; + }; + + CPU_PD1: cpu-pd1 { + #power-domain-cells = <0>; + power-domains = <&CLUSTER_PD>; + domain-idle-states = <&CPU_SPC>; + }; + + CPU_PD2: cpu-pd2 { + #power-domain-cells = <0>; + power-domains = <&CLUSTER_PD>; + domain-idle-states = <&CPU_SPC>; + }; + + CPU_PD3: cpu-pd3 { + #power-domain-cells = <0>; + power-domains = <&CLUSTER_PD>; + domain-idle-states = <&CPU_SPC>; + }; + + CLUSTER_PD: cluster-pd { + #power-domain-cells = <0>; + domain-idle-states = <&CLUSTER_RET>, <&CLUSTER_PWRDN>; + }; }; pmu { -- 2.7.4