From patchwork Mon Jun 19 16:18:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 694163 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id CD9BDEB64DA for ; Mon, 19 Jun 2023 16:19:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232241AbjFSQTH (ORCPT ); Mon, 19 Jun 2023 12:19:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36094 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232220AbjFSQTA (ORCPT ); Mon, 19 Jun 2023 12:19:00 -0400 Received: from mail-lf1-x129.google.com (mail-lf1-x129.google.com [IPv6:2a00:1450:4864:20::129]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 553CAE68 for ; Mon, 19 Jun 2023 09:18:58 -0700 (PDT) Received: by mail-lf1-x129.google.com with SMTP id 2adb3069b0e04-4f8777caaa1so370612e87.3 for ; Mon, 19 Jun 2023 09:18:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1687191536; x=1689783536; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=OoV/xjcktwt+INM9g5muSXeeb6bvGay0A0ymUJBmMcs=; b=wVfw2HzZLyB21AFz24OT1v5puatvlwL9EGXHSE6MFMhtyGjLNtUfwKxS0Sjo6JRuf9 ChSc8/dQJySBDrl7C8OthZd3Cso7txRX6yuTHh/j50rLjCZkQwthhKgaxmVTuAAG8uYU sVD/waXm/WurLUIsWPVP9NZecmOcH2aOUzrji9IfxIGgneSPBqxhrDwFZ+Zm/tLVZdYn 81RMIZjbJQxsGUNO84JIRZk8Ho4zz44M2UBx/XPO/amtSA9cpMt6AqzxsSWV9LXoHJfJ fpvAs1gqS4yF5CpOhZPi5K2ljzVVuAtP8sVUzMy/tAz0qgSUcqAhhnJdyygdH1796xWY iMrw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687191536; x=1689783536; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=OoV/xjcktwt+INM9g5muSXeeb6bvGay0A0ymUJBmMcs=; b=MY3S3oXfVJ/EdDp5j4Ab/4hcE7Fs5rkM4LndNLd5pzsEYQggjdUY6PWf5aoy4MaRwJ /wVUJOzZDw7Xqa5XQXENPNyiUM05/AdNA9J1SZq9epxXrNPAco6CCa+Zto+e6u1Rpjv3 hGw3AmEWjwMTJoa4wrASscPY4SGwY32UjLczy003vG6jK/jQOWJmPQNcTg7Oj6UUUtuf lAYN9Zaz7YrMJVn+0QFIYdK0SDJseuXDP/7e6xz9bsuPZXDCuGczEMtH61AH0+XFimwl bWt5hh5ghkVZYOo9zc7Ra5VXt2Lyt6bv14J5GvTzCYbjb+Yc884yC/gOl4hGciF05yxu Odkw== X-Gm-Message-State: AC+VfDwoGvj869jKog+oFtl8sBfz1VzIW5f4Igb5Hr4vwnnGxc34iEFq hY90cwJMyKjUGSRyoPlc+78+Yg== X-Google-Smtp-Source: ACHHUZ4wEakvLWzKzjneE+3eObFu3avXN3GJ4aK+FkBke233tbvDtXsaMZOiexB1i9NuwjPzE9HB2Q== X-Received: by 2002:a19:6d12:0:b0:4f7:604f:f4c8 with SMTP id i18-20020a196d12000000b004f7604ff4c8mr5568228lfc.18.1687191536578; Mon, 19 Jun 2023 09:18:56 -0700 (PDT) Received: from [192.168.1.101] (abyl242.neoplus.adsl.tpnet.pl. [83.9.31.242]) by smtp.gmail.com with ESMTPSA id c11-20020ac2530b000000b004b4cbc942a3sm4332824lfh.127.2023.06.19.09.18.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Jun 2023 09:18:56 -0700 (PDT) From: Konrad Dybcio Date: Mon, 19 Jun 2023 18:18:53 +0200 Subject: [PATCH RFT RFC 1/3] arm64: dts: qcom: sc8280xp: Add lower cluster idle states MIME-Version: 1.0 Message-Id: <20230619-topic-sc8280xp-idle-v1-1-35a8b98451d0@linaro.org> References: <20230619-topic-sc8280xp-idle-v1-0-35a8b98451d0@linaro.org> In-Reply-To: <20230619-topic-sc8280xp-idle-v1-0-35a8b98451d0@linaro.org> To: Andy Gross , Bjorn Andersson , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Johan Hovold Cc: Marijn Suijten , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Konrad Dybcio , Krzysztof Kozlowski , Konrad Dybcio X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1687191534; l=1687; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=I32j7um6NhN2jAjxwWACUhCcYczpx9OD9HWlBlfpRFA=; b=0b8ZFniFCU6cYHplkHHxQukfuPUxlOA71hmCyW9OJIJTV0N9G95XNLtoemi1Laok9S1n5KQYx 7TeuLTjesYLCJCF7TTPje5T71FtuAuf+nhWM6124/SYTmHo6Zre/alh X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Apart from a total LLCC + APSS power collapse, SC8280XP can also put either the DSU rail (CPU + L3), or VDD_CX in power collapse. Add support for these lower idle states to allow more flexibility. Signed-off-by: Konrad Dybcio --- arch/arm64/boot/dts/qcom/sc8280xp.dtsi | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/sc8280xp.dtsi b/arch/arm64/boot/dts/qcom/sc8280xp.dtsi index ac0596dfdbc4..d524f851cb53 100644 --- a/arch/arm64/boot/dts/qcom/sc8280xp.dtsi +++ b/arch/arm64/boot/dts/qcom/sc8280xp.dtsi @@ -285,7 +285,23 @@ BIG_CPU_SLEEP_0: cpu-sleep-1-0 { }; domain-idle-states { - CLUSTER_SLEEP_0: cluster-sleep-0 { + CLUSTER_SLEEP_L3_PC: cluster-sleep-0 { + compatible = "domain-idle-state"; + arm,psci-suspend-param = <0x41000044>; + entry-latency-us = <2752>; + exit-latency-us = <3048>; + min-residency-us = <6118>; + }; + + CLUSTER_SLEEP_CX_OFF: cluster-sleep-1 { + compatible = "domain-idle-state"; + arm,psci-suspend-param = <0x41002344>; + entry-latency-us = <3263>; + exit-latency-us = <4562>; + min-residency-us = <8467>; + }; + + CLUSTER_SLEEP_APSS_OFF: cluster-sleep-2 { compatible = "domain-idle-state"; arm,psci-suspend-param = <0x4100c344>; entry-latency-us = <3263>; @@ -632,7 +648,7 @@ CPU_PD7: power-domain-cpu7 { CLUSTER_PD: power-domain-cpu-cluster0 { #power-domain-cells = <0>; - domain-idle-states = <&CLUSTER_SLEEP_0>; + domain-idle-states = <&CLUSTER_SLEEP_L3_PC &CLUSTER_SLEEP_CX_OFF &CLUSTER_SLEEP_APSS_OFF>; }; }; From patchwork Mon Jun 19 16:18:55 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 694162 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id A676AEB64DB for ; Mon, 19 Jun 2023 16:19:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232233AbjFSQTJ (ORCPT ); Mon, 19 Jun 2023 12:19:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36136 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232117AbjFSQTE (ORCPT ); Mon, 19 Jun 2023 12:19:04 -0400 Received: from mail-lf1-x131.google.com (mail-lf1-x131.google.com [IPv6:2a00:1450:4864:20::131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9DC39E73 for ; Mon, 19 Jun 2023 09:19:00 -0700 (PDT) Received: by mail-lf1-x131.google.com with SMTP id 2adb3069b0e04-4f762b3227dso4394931e87.1 for ; Mon, 19 Jun 2023 09:19:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1687191539; x=1689783539; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=NeMEcI4+yKDWLM0Xoh1q+uyo2M+zCM82XkXiL0IHChQ=; b=ERW7c9xDG11GsK8JfvPDwgUNzimXYc7k+0n+cwTtPkx+e/eN0Mc4b7g36HaVVsUT+2 ZwcynuPACuf5rZr2c+/pXN9FyIhLZ7U8CFeaslkmnjVpcy0SHCuaxcDOGMISALDUdcRL sPUNNeCvRlt7d3PUcwA6sVCvxjfL/E6pOx8hYTSgmje7gyKTVGGVtFt5Kpy7t5owt/bg t6Hnm1z6KXcDTrz5bMOr+avoiyHZ8umjH68N60bfHlmapbzIsPHF0194rN665irS50v1 NUxZWnvzBtSBADz4Wuae4ug52F/Of06tqhh1niZWQ+4ytTuWWnqj5KfMue7ScIQbiSjt KLZw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687191539; x=1689783539; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=NeMEcI4+yKDWLM0Xoh1q+uyo2M+zCM82XkXiL0IHChQ=; b=XrmwsSHkZrwiFwtVB0XZbe/ksZX5wQsxco+9xnRGGzMlCMQ7kxij8pdt84CnYXYy6N uQPmgXyFBCy3WKPf9/GpCwAWy+yI7PnkuaioXQ1L5bFAwh35/HeWnpZQPAuuTJrtnVJU myw0a0WDZpzkgPLTAqTXBqlKplvf+YNUyNHRiMQL+13jlL09vPJaNkLF/bVcHOWWqLH6 HRPnH+Bpxfjw7VI2914NG6gH0HJ3ot9Jhmu1vBcMSbNJFP2n9lj++1nKdbu1mAQrKGiy t5ijEu7SbDs+4YFRE3wFs7nBvultDlMUT2ZVgIiSts9JBY/kq95jKFu07XxwZXchyaUC Q3Fw== X-Gm-Message-State: AC+VfDw/W/L8SFWY9Lz2acN66gFo0OXRj80wdr7DtREuUOsf1ZZcunOk N/xXpP1NjYXDD8NbkWA8/jYU8A== X-Google-Smtp-Source: ACHHUZ6iNnONLcUHaRD6LwY1bDzyrM6RE9wksQs+lZAEVUHBzQ3Teny0MCjBD4PNxgZlft0/pI5ggg== X-Received: by 2002:a19:5f5d:0:b0:4f8:5e62:b94b with SMTP id a29-20020a195f5d000000b004f85e62b94bmr1804453lfj.9.1687191539015; Mon, 19 Jun 2023 09:18:59 -0700 (PDT) Received: from [192.168.1.101] (abyl242.neoplus.adsl.tpnet.pl. [83.9.31.242]) by smtp.gmail.com with ESMTPSA id c11-20020ac2530b000000b004b4cbc942a3sm4332824lfh.127.2023.06.19.09.18.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Jun 2023 09:18:58 -0700 (PDT) From: Konrad Dybcio Date: Mon, 19 Jun 2023 18:18:55 +0200 Subject: [PATCH RFT RFC 3/3] arm64: dts: qcom: sc8280xp: Fix up idle state periods MIME-Version: 1.0 Message-Id: <20230619-topic-sc8280xp-idle-v1-3-35a8b98451d0@linaro.org> References: <20230619-topic-sc8280xp-idle-v1-0-35a8b98451d0@linaro.org> In-Reply-To: <20230619-topic-sc8280xp-idle-v1-0-35a8b98451d0@linaro.org> To: Andy Gross , Bjorn Andersson , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Johan Hovold Cc: Marijn Suijten , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Konrad Dybcio , Krzysztof Kozlowski , Konrad Dybcio X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1687191534; l=1802; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=mq7mfTgr9ZtvOEPLMaimjrbNtQBLNamSOSbjgI89DqQ=; b=5zkt0CsawhYgMHbQ+uC07azdfetKN9uRQNsiWgI4WMR5ahWeGTk+03QDZRCGWFHV2YpGTc64b bDozYqakncYDn33+Klx7kP0OU9HayubPhGh42pPDLv++NgW8eB+lqCg X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Some of the values were wrong, which may have painted a wrong picture to the scheduler. Fix it. Fixes: 152d1faf1e2f ("arm64: dts: qcom: add SC8280XP platform") Signed-off-by: Konrad Dybcio --- arch/arm64/boot/dts/qcom/sc8280xp.dtsi | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/sc8280xp.dtsi b/arch/arm64/boot/dts/qcom/sc8280xp.dtsi index b8f2ec9477f5..d7894465a0d2 100644 --- a/arch/arm64/boot/dts/qcom/sc8280xp.dtsi +++ b/arch/arm64/boot/dts/qcom/sc8280xp.dtsi @@ -277,9 +277,9 @@ LITTLE_CPU_SLEEP_1: cpu-sleep-0-1 { compatible = "arm,idle-state"; idle-state-name = "little-rail-power-collapse"; arm,psci-suspend-param = <0x40000004>; - entry-latency-us = <355>; - exit-latency-us = <909>; - min-residency-us = <3934>; + entry-latency-us = <702>; + exit-latency-us = <915>; + min-residency-us = <4001>; local-timer-stop; }; @@ -297,9 +297,9 @@ BIG_CPU_SLEEP_1: cpu-sleep-1-1 { compatible = "arm,idle-state"; idle-state-name = "big-rail-power-collapse"; arm,psci-suspend-param = <0x40000004>; - entry-latency-us = <241>; - exit-latency-us = <1461>; - min-residency-us = <4488>; + entry-latency-us = <526>; + exit-latency-us = <1854>; + min-residency-us = <5555>; local-timer-stop; }; }; @@ -324,9 +324,9 @@ CLUSTER_SLEEP_CX_OFF: cluster-sleep-1 { CLUSTER_SLEEP_APSS_OFF: cluster-sleep-2 { compatible = "domain-idle-state"; arm,psci-suspend-param = <0x4100c344>; - entry-latency-us = <3263>; + entry-latency-us = <3638>; exit-latency-us = <6562>; - min-residency-us = <9987>; + min-residency-us = <9826>; }; }; };