diff mbox series

[v2] arm64: dts: qcom: sc7280: Update domain-idle-states for cluster sleep

Message ID 20240109-qcm6490_cluster_sleep-v2-1-8f94f1ad188d@quicinc.com
State Accepted
Commit db5d137e81bcce6a2506c1d056e5834a53405a5e
Headers show
Series [v2] arm64: dts: qcom: sc7280: Update domain-idle-states for cluster sleep | expand

Commit Message

Maulik Shah Jan. 9, 2024, 3:58 p.m. UTC
QCM6490 uses Trustzone as firmware whereas SC7280 uses arm trusted firmware.
The PSCI suspend param and the number of domain-idle-states supported is
different in Trustzone for cluster sleep.

Move the arm trusted firmware supported domain-idle-states in chrome specific
sc7280-chrome-common.dtsi and add the Trustzone supported sleep states as default
domain-idle-states in sc7280.dtsi

Signed-off-by: Maulik Shah <quic_mkshah@quicinc.com>
---
Changes in v2:
- Move chrome specific domain-idle-states to sc7280-chrome-common.dtsi
- Keep LA+LE+WP+friends values as default
- Add additional cluster sleep states
- Link to v1: https://lore.kernel.org/lkml/20240105070223.11415-1-quic_mkshah@quicinc.com/
---
 arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi | 17 +++++++++++++
 arch/arm64/boot/dts/qcom/sc7280.dtsi               | 28 ++++++++++++++++------
 2 files changed, 38 insertions(+), 7 deletions(-)


---
base-commit: bffdfd2e7e63175ae261131a620f809d946cf9a7
change-id: 20240109-qcm6490_cluster_sleep-2c4f175814b6

Best regards,

Comments

Bjorn Andersson Feb. 7, 2024, 4:46 a.m. UTC | #1
On Tue, 09 Jan 2024 21:28:52 +0530, Maulik Shah wrote:
> QCM6490 uses Trustzone as firmware whereas SC7280 uses arm trusted firmware.
> The PSCI suspend param and the number of domain-idle-states supported is
> different in Trustzone for cluster sleep.
> 
> Move the arm trusted firmware supported domain-idle-states in chrome specific
> sc7280-chrome-common.dtsi and add the Trustzone supported sleep states as default
> domain-idle-states in sc7280.dtsi
> 
> [...]

Applied, thanks!

[1/1] arm64: dts: qcom: sc7280: Update domain-idle-states for cluster sleep
      commit: db5d137e81bcce6a2506c1d056e5834a53405a5e

Best regards,
diff mbox series

Patch

diff --git a/arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi b/arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi
index c4d00a81da39..3fcf2e65afca 100644
--- a/arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi
+++ b/arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi
@@ -18,6 +18,7 @@ 
  */
 
 /delete-node/ &cdsp_mem;
+/delete-node/ &domain_idle_states;
 /delete-node/ &gpu_zap_mem;
 /delete-node/ &gpu_zap_shader;
 /delete-node/ &hyp_mem;
@@ -26,6 +27,18 @@ 
 /delete-node/ &sec_apps_mem;
 
 / {
+	cpus {
+		domain_idle_states: domain-idle-states {
+			CLUSTER_SLEEP_0: cluster-sleep-0 {
+				compatible = "domain-idle-state";
+				arm,psci-suspend-param = <0x40003444>;
+				entry-latency-us = <2752>;
+				exit-latency-us = <6562>;
+				min-residency-us = <9926>;
+			};
+		};
+	};
+
 	reserved-memory {
 		camera_mem: memory@8ad00000 {
 			reg = <0x0 0x8ad00000 0x0 0x500000>;
@@ -39,6 +52,10 @@ 
 	};
 };
 
+&CLUSTER_PD {
+	domain-idle-states = <&CLUSTER_SLEEP_0>;
+};
+
 &lpass_aon {
 	status = "okay";
 };
diff --git a/arch/arm64/boot/dts/qcom/sc7280.dtsi b/arch/arm64/boot/dts/qcom/sc7280.dtsi
index 83b5b76ba179..9f4df595dd21 100644
--- a/arch/arm64/boot/dts/qcom/sc7280.dtsi
+++ b/arch/arm64/boot/dts/qcom/sc7280.dtsi
@@ -453,15 +453,29 @@ 
 			};
 		};
 
-		domain-idle-states {
-			CLUSTER_SLEEP_0: cluster-sleep-0 {
+		domain_idle_states: domain-idle-states {
+			CLUSTER_SLEEP_APSS_OFF: cluster-sleep-0 {
 				compatible = "domain-idle-state";
-				idle-state-name = "cluster-power-down";
-				arm,psci-suspend-param = <0x40003444>;
+				arm,psci-suspend-param = <0x41000044>;
+				entry-latency-us = <2752>;
+				exit-latency-us = <3048>;
+				min-residency-us = <6118>;
+			};
+
+			CLUSTER_SLEEP_CX_RET: cluster-sleep-1 {
+				compatible = "domain-idle-state";
+				arm,psci-suspend-param = <0x41001344>;
 				entry-latency-us = <3263>;
+				exit-latency-us = <4562>;
+				min-residency-us = <8467>;
+			};
+
+			CLUSTER_SLEEP_LLCC_OFF: cluster-sleep-2 {
+				compatible = "domain-idle-state";
+				arm,psci-suspend-param = <0x4100b344>;
+				entry-latency-us = <3638>;
 				exit-latency-us = <6562>;
-				min-residency-us = <9926>;
-				local-timer-stop;
+				min-residency-us = <9826>;
 			};
 		};
 	};
@@ -872,7 +886,7 @@ 
 
 		CLUSTER_PD: power-domain-cluster {
 			#power-domain-cells = <0>;
-			domain-idle-states = <&CLUSTER_SLEEP_0>;
+			domain-idle-states = <&CLUSTER_SLEEP_APSS_OFF &CLUSTER_SLEEP_CX_RET &CLUSTER_SLEEP_LLCC_OFF>;
 		};
 	};