* [PATCH v2] arm64: dts: qcom: x1e80100-dell-xps13-9345: Add thermal zones
@ 2026-10-22 20:18 Liviu Nicoara
0 siblings, 0 replies; only message in thread
From: Liviu Nicoara @ 2026-10-22 20:18 UTC (permalink / raw)
To: Bjorn Andersson, Konrad Dybcio
Cc: Konrad Dybcio, Abel Vesa, Abel Vesa, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Aleksandrs Vinarskis,
linux-arm-msm, devicetree, linux-kernel
The XPS 13 9345 has seven board thermistors on the PMK8550 VADC: AMUX1
to AMUX5 THM and AMUX1 and AMUX2 GPIO, each with a 100k pull-up. The
ADC configuration in Dell's Windows driver package lists the same seven
channels as SYS_THERM1 to SYS_THERM7, the two GPIO channels first and
the five THM channels after them. Name the zones after that list: where
each thermistor sits on the board is not established, and a name that
guesses a location misleads whoever reads it next.
The ACPI tables define seven ADC thermal zones, TZ31 to TZ37. Three of
them, TZ32 to TZ34, carry passive trips that throttle all CPUs and the
GPU; the other four sit at 100 C. The tables do not name a zone's
channel. Taken in SYS_THERM order, TZ32 to TZ34 are SYS_THERM2 to
SYS_THERM4. Heating the board supports that order at one point: a
charger on the right USB-C port warms SYS_THERM4 well ahead of every
other channel.
The passive trips follow the thermal mode chosen in the BIOS setup
(Thermal Management: Optimized, Cool, Quiet or Ultra Performance),
which the EC reports and which cannot be read without an EC driver.
Use the values of Optimized, the default: 53.8 C on SYS_THERM2, 62.8 C
on SYS_THERM3, 61.8 C on SYS_THERM4. The critical trips are the tables'
114.8 C. The other four channels get report-only zones, as on the CRD,
and all seven are put in thermal-monitor mode.
Assisted-by: LLM
Signed-off-by: Liviu Nicoara <lnicoara@thinkoid.org>
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Tested-by: Abel Vesa <abel.vesa@oss.qualcomm.com>
Reviewed-by: Abel Vesa <abel.vesa@oss.qualcomm.com>
---
Notes:
v2: name the zones SYS_THERM1 to SYS_THERM7 after the ADC configuration
instead of guessed board locations, and order them the same way. The
"left charger" placement of AMUX2 GPIO did not hold up against a second
owner's ten-second measurements, and the SSD one is uncertain:
https://lore.kernel.org/all/NCQ5O8k2_GpmJZBjDzgZL67uwdiYmmuSudO9VmdRaFTDq0u7aec6at00VYbzdwwSVvgJnLnGxewwp_TVO9oTjM2pAjP_LoiURf9JCIKXB-w=@vinarskis.com/
Channels, trips and cooling maps are unchanged; the v1 tags are kept
for what is a rename.
Tested on v7.2.6 with the ADC_TM driver (7.3-rc1) and aac6b2ca472e
backported: the seven zones read within 0.01 C of their IIO channels.
With SYS_THERM2's passive trip moved just above the zone and a
single-core load, the crossing throttled all three CPU clusters and the
GPU through the ADC_TM threshold interrupt, and the throttle released
at the trip less its hysteresis. The v2 rename was built and checked
with W=1 dtbs_check on qcom arm64-for-7.4; no warnings.
.../dts/qcom/x1e80100-dell-xps13-9345.dts | 169 ++++++++++++++++++
1 file changed, 169 insertions(+)
diff --git a/arch/arm64/boot/dts/qcom/x1e80100-dell-xps13-9345.dts b/arch/arm64/boot/dts/qcom/x1e80100-dell-xps13-9345.dts
index f48e6bc35006..bb7d91ed08ba 100644
--- a/arch/arm64/boot/dts/qcom/x1e80100-dell-xps13-9345.dts
+++ b/arch/arm64/boot/dts/qcom/x1e80100-dell-xps13-9345.dts
@@ -326,6 +326,145 @@ vreg_wcn_3p3: regulator-wcn-3p3 {
regulator-boot-on;
};
+ thermal-zones {
+ sys-therm1-thermal {
+ thermal-sensors = <&pmk8550_vadc ADC5_GEN3_AMUX1_GPIO_100K_PU(1)>;
+ };
+
+ sys-therm2-thermal {
+ critical-action = "shutdown";
+ polling-delay-passive = <1000>;
+
+ thermal-sensors = <&pmk8550_vadc ADC5_GEN3_AMUX2_GPIO_100K_PU(1)>;
+
+ trips {
+ sys_therm2_alert0: trip-point0 {
+ temperature = <53800>;
+ hysteresis = <1000>;
+ type = "passive";
+ };
+
+ sys-therm2-critical {
+ temperature = <114800>;
+ hysteresis = <1000>;
+ type = "critical";
+ };
+ };
+
+ cooling-maps {
+ map0 {
+ trip = <&sys_therm2_alert0>;
+ cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu4 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu5 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu6 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu7 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu8 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu9 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu10 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu11 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+ };
+ };
+ };
+
+ sys-therm3-thermal {
+ critical-action = "shutdown";
+ polling-delay-passive = <1000>;
+
+ thermal-sensors = <&pmk8550_vadc ADC5_GEN3_AMUX1_THM_100K_PU(1)>;
+
+ trips {
+ sys_therm3_alert0: trip-point0 {
+ temperature = <62800>;
+ hysteresis = <1000>;
+ type = "passive";
+ };
+
+ sys-therm3-critical {
+ temperature = <114800>;
+ hysteresis = <1000>;
+ type = "critical";
+ };
+ };
+
+ cooling-maps {
+ map0 {
+ trip = <&sys_therm3_alert0>;
+ cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu4 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu5 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu6 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu7 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu8 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu9 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu10 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu11 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+ };
+ };
+ };
+
+ /* Warms with a charger on the right USB-C port */
+ sys-therm4-thermal {
+ critical-action = "shutdown";
+ polling-delay-passive = <1000>;
+
+ thermal-sensors = <&pmk8550_vadc ADC5_GEN3_AMUX2_THM_100K_PU(1)>;
+
+ trips {
+ sys_therm4_alert0: trip-point0 {
+ temperature = <61800>;
+ hysteresis = <1000>;
+ type = "passive";
+ };
+
+ sys-therm4-critical {
+ temperature = <114800>;
+ hysteresis = <1000>;
+ type = "critical";
+ };
+ };
+
+ cooling-maps {
+ map0 {
+ trip = <&sys_therm4_alert0>;
+ cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu4 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu5 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu6 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu7 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu8 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu9 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu10 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&cpu11 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+ <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+ };
+ };
+ };
+
+ sys-therm5-thermal {
+ thermal-sensors = <&pmk8550_vadc ADC5_GEN3_AMUX3_THM_100K_PU(1)>;
+ };
+
+ sys-therm6-thermal {
+ thermal-sensors = <&pmk8550_vadc ADC5_GEN3_AMUX4_THM_100K_PU(1)>;
+ };
+
+ sys-therm7-thermal {
+ thermal-sensors = <&pmk8550_vadc ADC5_GEN3_AMUX5_THM_100K_PU(1)>;
+ };
+ };
+
wcn7850-pmu {
compatible = "qcom,wcn7850-pmu";
@@ -1025,6 +1164,36 @@ rtmr0_1p8_reg_en: rtmr0-1p8-reg-en-state {
};
};
+&pmk8550_vadc {
+ channel@144 {
+ qcom,adc-tm;
+ };
+
+ channel@145 {
+ qcom,adc-tm;
+ };
+
+ channel@146 {
+ qcom,adc-tm;
+ };
+
+ channel@147 {
+ qcom,adc-tm;
+ };
+
+ channel@148 {
+ qcom,adc-tm;
+ };
+
+ channel@14a {
+ qcom,adc-tm;
+ };
+
+ channel@14b {
+ qcom,adc-tm;
+ };
+};
+
&qupv3_0 {
status = "okay";
};
base-commit: d053e38e614fb2e383b298ce8fc308a780d7f209
--
2.56.0
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-10-22 20:18 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-10-22 20:18 [PATCH v2] arm64: dts: qcom: x1e80100-dell-xps13-9345: Add thermal zones Liviu Nicoara
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®