Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp1495293pxb; Fri, 26 Feb 2021 12:13:30 -0800 (PST) X-Google-Smtp-Source: ABdhPJx14zbusnrwJZA+r/qFMzkcYrjC3pxdOYBjE3gIHOuZKYYPDVd3cXn/jXsavR8m+6z6Svmb X-Received: by 2002:a17:906:e0b:: with SMTP id l11mr5328412eji.523.1614370410285; Fri, 26 Feb 2021 12:13:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614370410; cv=none; d=google.com; s=arc-20160816; b=j2XWA7DHTAjmIgAatSRyN1a44AI11CIaawVL7Y7EfS9pWsVfLRD9mQrIXwrWAKYZV5 DR9Tulq4sHJfVhQ6BdqVuD9BLjAqaYCa7K3MlqyJ+yBOV4Erg6T9rDwSNTB89ij51z7T TspOmernLExG8UIbg9i4eN4HVVwNMJNP6kt8wYzymUC/Qu7Md4oIFMYJjCMr93V4c6LU PeJYyeFhyQU+nlHv979+bGzQny8IuhbKUwb5myP8cfcRBTn9H2CShVLWlPUpdYutIywG Lb3DDFiMlVNe27M725hELbDMTh6+O9NSLV4ij9kBxZBlmm5vkNS9OP1XGEss1LykKCY4 LsZQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=IwtG0yV76MpUssiXXbD3yLRF8/RDRYjUk/pzUt7qvMs=; b=OK8pdU/k2c39WG1yIJhakaMP2aECORbKvAwzCn5rr4mdm5n1v9MLYnUjy1/yg96dln dDRYg40AEA20t12tGRwK0F1PSHlum0CtVocVDXV6h1eerxi9rXx745qu1Hm5tx4deLJz sct3mqSMsPEoHJv42Tkia/hr+n1ZY2AFJehGkAn5PVlv7Gw4k3JLK1S223Y/ujyS49fe +em7CfR2jR9FFRb14Vj+YTiS1PA6Z0Zkla2GYEkmLH+1gZzRHoKpyEAmZrgo2Lt/fsoz fJ9JtJTEAihJ88xu1mDMIp7yCzvBWmeSW/Lon77n+l5kKFwa/4fCIZ/mUjF/G3VjOC/o Fh2Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id cw8si6592504ejc.218.2021.02.26.12.13.06; Fri, 26 Feb 2021 12:13:30 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230070AbhBZUMC (ORCPT + 99 others); Fri, 26 Feb 2021 15:12:02 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38770 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230220AbhBZUIs (ORCPT ); Fri, 26 Feb 2021 15:08:48 -0500 Received: from m-r1.th.seeweb.it (m-r1.th.seeweb.it [IPv6:2001:4b7a:2000:18::170]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 97B80C0617AA; Fri, 26 Feb 2021 12:05:52 -0800 (PST) Received: from localhost.localdomain (abab236.neoplus.adsl.tpnet.pl [83.6.165.236]) by m-r1.th.seeweb.it (Postfix) with ESMTPA id 0A1071FBB2; Fri, 26 Feb 2021 21:05:49 +0100 (CET) From: Konrad Dybcio To: phone-devel@vger.kernel.org Cc: ~postmarketos/upstreaming@lists.sr.ht, martin.botka@somainline.org, angelogioacchino.delregno@somainline.org, marijn.suijten@somainline.org, Konrad Dybcio , Andy Gross , Bjorn Andersson , Amit Kucheria , Zhang Rui , Daniel Lezcano , Rob Herring , linux-arm-msm@vger.kernel.org, linux-pm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 17/41] arm64: dts: qcom: sdm630: Add thermal-zones configuration Date: Fri, 26 Feb 2021 21:03:47 +0100 Message-Id: <20210226200414.167762-18-konrad.dybcio@somainline.org> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210226200414.167762-1-konrad.dybcio@somainline.org> References: <20210226200414.167762-1-konrad.dybcio@somainline.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add a basic thermal-zones configuration to make sure the SoC doesn't overheat itself to death. Signed-off-by: AngeloGioacchino Del Regno Signed-off-by: Konrad Dybcio --- arch/arm64/boot/dts/qcom/sdm630.dtsi | 173 +++++++++++++++++++++++++++ 1 file changed, 173 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/sdm630.dtsi b/arch/arm64/boot/dts/qcom/sdm630.dtsi index ffc18d0dee9e..08e499229396 100644 --- a/arch/arm64/boot/dts/qcom/sdm630.dtsi +++ b/arch/arm64/boot/dts/qcom/sdm630.dtsi @@ -521,6 +521,179 @@ modem_smp2p_in: slave-kernel { }; }; + thermal-zones { + aoss-thermal { + polling-delay-passive = <250>; + polling-delay = <1000>; + + thermal-sensors = <&tsens 0>; + + trips { + aoss_alert0: trip-point0 { + temperature = <105000>; + hysteresis = <1000>; + type = "hot"; + }; + }; + }; + + cpuss0-thermal { + polling-delay-passive = <250>; + polling-delay = <1000>; + + thermal-sensors = <&tsens 1>; + + trips { + cpuss0_alert0: trip-point0 { + temperature = <125000>; + hysteresis = <1000>; + type = "hot"; + }; + }; + }; + + cpuss1-thermal { + polling-delay-passive = <250>; + polling-delay = <1000>; + + thermal-sensors = <&tsens 2>; + + trips { + cpuss1_alert0: trip-point0 { + temperature = <125000>; + hysteresis = <1000>; + type = "hot"; + }; + }; + }; + + cpu0-thermal { + polling-delay-passive = <250>; + polling-delay = <1000>; + + thermal-sensors = <&tsens 3>; + + trips { + cpu0_alert0: trip-point0 { + temperature = <70000>; + hysteresis = <1000>; + type = "passive"; + }; + + cpu0_crit: cpu_crit { + temperature = <110000>; + hysteresis = <1000>; + type = "critical"; + }; + }; + }; + + cpu1-thermal { + polling-delay-passive = <250>; + polling-delay = <1000>; + + thermal-sensors = <&tsens 4>; + + trips { + cpu1_alert0: trip-point0 { + temperature = <70000>; + hysteresis = <1000>; + type = "passive"; + }; + + cpu1_crit: cpu_crit { + temperature = <110000>; + hysteresis = <1000>; + type = "critical"; + }; + }; + }; + + cpu2-thermal { + polling-delay-passive = <250>; + polling-delay = <1000>; + + thermal-sensors = <&tsens 5>; + + trips { + cpu2_alert0: trip-point0 { + temperature = <70000>; + hysteresis = <1000>; + type = "passive"; + }; + + cpu2_crit: cpu_crit { + temperature = <110000>; + hysteresis = <1000>; + type = "critical"; + }; + }; + }; + + cpu3-thermal { + polling-delay-passive = <250>; + polling-delay = <1000>; + + thermal-sensors = <&tsens 6>; + + trips { + cpu3_alert0: trip-point0 { + temperature = <70000>; + hysteresis = <1000>; + type = "passive"; + }; + + cpu3_crit: cpu_crit { + temperature = <110000>; + hysteresis = <1000>; + type = "critical"; + }; + }; + }; + + /* + * According to what downstream DTS says, + * the entire power efficient cluster has + * only a single thermal sensor. + */ + + pwr-cluster-thermal { + polling-delay-passive = <250>; + polling-delay = <1000>; + + thermal-sensors = <&tsens 7>; + + trips { + pwr_cluster_alert0: trip-point0 { + temperature = <70000>; + hysteresis = <1000>; + type = "passive"; + }; + + pwr_cluster_crit: cpu_crit { + temperature = <110000>; + hysteresis = <1000>; + type = "critical"; + }; + }; + }; + + gpu-thermal { + polling-delay-passive = <250>; + polling-delay = <1000>; + + thermal-sensors = <&tsens 8>; + + trips { + gpu_alert0: trip-point0 { + temperature = <90000>; + hysteresis = <1000>; + type = "hot"; + }; + }; + }; + }; + soc { #address-cells = <1>; #size-cells = <1>; -- 2.30.1