[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20260114-acpm-tmu-v1-0-cfe56d93e90f@linaro.org>
Date: Wed, 14 Jan 2026 14:16:28 +0000
From: Tudor Ambarus <tudor.ambarus@...aro.org>
To: "Rafael J. Wysocki" <rafael@...nel.org>,
Daniel Lezcano <daniel.lezcano@...aro.org>, Zhang Rui <rui.zhang@...el.com>,
Lukasz Luba <lukasz.luba@....com>, Rob Herring <robh@...nel.org>,
Krzysztof Kozlowski <krzk+dt@...nel.org>,
Conor Dooley <conor+dt@...nel.org>, Lee Jones <lee@...nel.org>,
Krzysztof Kozlowski <krzk@...nel.org>,
Alim Akhtar <alim.akhtar@...sung.com>,
Peter Griffin <peter.griffin@...aro.org>,
André Draszik <andre.draszik@...aro.org>,
Bartlomiej Zolnierkiewicz <bzolnier@...il.com>, Kees Cook <kees@...nel.org>,
"Gustavo A. R. Silva" <gustavoars@...nel.org>
Cc: willmcvicker@...gle.com, jyescas@...gle.com, shin.son@...sung.com,
linux-pm@...r.kernel.org, devicetree@...r.kernel.org,
linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-samsung-soc@...r.kernel.org, linux-hardening@...r.kernel.org,
Tudor Ambarus <tudor.ambarus@...aro.org>
Subject: [PATCH 0/8] thermal: samsung: Add support for Google GS101 TMU
This series adds support for the Thermal Management Unit (TMU) on the
Google GS101 SoC (Tensor).
The GS101 TMU implementation differs from previous Exynos generations.
It utilizes a hybrid architecture where control responsibilities are
split between the kernel and the Alive Clock and Power Manager (ACPM)
firmware.
Dependencies
============
1. The thermal driver patch (5) depends on the firmware helpers (4).
2. Typical dependency of the DT patch (7) depending on the bindings
patches (1), (2) and (3) (to pass dtbs_check)
3. defconfig (8) logical dependency on (5).
The bindings patches (1-3) are independent of each other. They can be
applied in any order, though logical grouping (Firmware -> Thermal)
is still nice for reading.
The Firmware driver (4) is independent.
Given the dependencies, I'd suggest everything to go through the
Samsung SoC tree, with ACKs from the MFD and Thermal maintainers.
If the Thermal maintainers prefer to take patch 5 via their tree, an
immutable branch containing patch 4 (firmware) will be required from the
Samsung SoC tree to serve as a base.
Architecture Overview
=====================
1. Firmware Responsibility (ACPM):
- Initializes the hardware.
- Performs ADC conversions and temperature calibration.
- Manages thermal thresholds and hysteresis configuration.
- Exposes a high-level protocol for temperature reading and trip
point configuration.
2. Kernel Responsibility:
- Communicates with ACPM via the mailbox protocol to set thresholds
and read temperatures.
- Monitors the interrupt pending status registers directly via a
syscon interface.
- Maps physical hardware interrupts to logical thermal zones.
Sensor Mapping (One-to-Many)
============================
A key aspect of this hardware is the mapping between the logical "ACPM
Sensors" and the physical TMU sensors.
The SoC contains multiple physical temperature sensors scattered across
the die (e.g., near specific cores). However, the ACPM firmware abstracts
these into logical groups (Clusters).
- ACPM Sensor 0 (Big Cluster): Aggregates physical sensors 0, 6, 7, 8, 9.
- ACPM Sensor 1 (Mid Cluster): Aggregates physical sensors 4, 5.
- ACPM Sensor 2 (Little Cluster): Aggregates physical sensors 1, 2.
While ACPM reports a single temperature per logical sensor (likely the
max of the group), the thermal interrupts are raised by the physical
blocks individually.
Therefore, the driver is designed to map these physical interrupt bits
back to their logical parent. When an interrupt fires, the driver checks
the syscon register against the masks defined above. If any bit within
a group's mask is set, the corresponding logical thermal zone is updated.
Signed-off-by: Tudor Ambarus <tudor.ambarus@...aro.org>
---
Tudor Ambarus (8):
dt-bindings: thermal: Add Google GS101 TMU
dt-bindings: firmware: google,gs101-acpm-ipc: Add TMU child node
dt-bindings: mfd: Add Google GS101 TMU Syscon
firmware: samsung: acpm: Add TMU protocol support
thermal: samsung: Add support for GS101 TMU
MAINTAINERS: Add entry for Samsung Exynos ACPM thermal driver
arm64: dts: exynos: gs101: Add thermal management unit
arm64: defconfig: enable Exynos ACPM thermal support
.../bindings/firmware/google,gs101-acpm-ipc.yaml | 17 +
.../bindings/mfd/google,gs101-tmu-syscon.yaml | 37 ++
.../bindings/thermal/google,gs101-tmu-top.yaml | 64 +++
MAINTAINERS | 8 +
arch/arm64/boot/dts/exynos/google/gs101-tmu.dtsi | 209 +++++++
arch/arm64/boot/dts/exynos/google/gs101.dtsi | 22 +
arch/arm64/configs/defconfig | 1 +
drivers/firmware/samsung/Makefile | 1 +
drivers/firmware/samsung/exynos-acpm-tmu.c | 212 +++++++
drivers/firmware/samsung/exynos-acpm-tmu.h | 33 ++
drivers/firmware/samsung/exynos-acpm.c | 12 +
drivers/thermal/samsung/Kconfig | 16 +
drivers/thermal/samsung/Makefile | 2 +
drivers/thermal/samsung/acpm-tmu.c | 638 +++++++++++++++++++++
.../linux/firmware/samsung/exynos-acpm-protocol.h | 24 +
15 files changed, 1296 insertions(+)
---
base-commit: fefc12a70eb12e0b04f0b59b623965dd3ab1f4ba
change-id: 20260113-acpm-tmu-27e21f0e2c3b
Best regards,
--
Tudor Ambarus <tudor.ambarus@...aro.org>
Powered by blists - more mailing lists