[PATCH 1/4] dt-bindings: hwmon: adt7475: Add #thermal-sensor-cells
From: Davíð Steinn Geirsson
Date: Fri Nov 13 2026 - 19:41:49 EST
The ADT7473, ADT7475, ADT7476 and ADT7490 measure two remote
temperatures and their own. Add the "#thermal-sensor-cells" property so
that thermal zones can use these as sensors. Its single cell selects the
temperature channel: 0 for Remote 1, 1 for Local and 2 for Remote 2.
Signed-off-by: Davíð Steinn Geirsson <david@xxxxxx>
---
This patch was written with Claude Code, using the models Claude
Opus 5.5 and Claude Fable 5.2. They wrote the code and the initial
commit message draft, which I cleaned up. I directed the design,
reviewed the result, compared against the datasheet as far as I
could, and ran tests including on actual hardware.
.../devicetree/bindings/hwmon/adt7475.yaml | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
diff --git a/Documentation/devicetree/bindings/hwmon/adt7475.yaml b/Documentation/devicetree/bindings/hwmon/adt7475.yaml
index 43e9fe225870..cbd44bf6759a 100644
--- a/Documentation/devicetree/bindings/hwmon/adt7475.yaml
+++ b/Documentation/devicetree/bindings/hwmon/adt7475.yaml
@@ -73,6 +73,14 @@ properties:
- 2: PWM flags 0 or PWM_POLARITY_INVERTED
- 3: The default PWM duty cycle in nanoseconds, defaults to period.
+ "#thermal-sensor-cells":
+ const: 1
+ description: |
+ The cell is the temperature channel.
+ - 0: Remote 1
+ - 1: Local
+ - 2: Remote 2
+
patternProperties:
"^adi,bypass-attenuator-in[0-4]$":
description: |
@@ -111,6 +119,13 @@ required:
- compatible
- reg
+allOf:
+ - if:
+ required:
+ - "#thermal-sensor-cells"
+ then:
+ $ref: /schemas/thermal/thermal-sensor.yaml#
+
additionalProperties: false
examples:
@@ -128,6 +143,7 @@ examples:
adi,pin10-function = "smbalert#";
adi,pin14-function = "tach4";
#pwm-cells = <3>;
+ #thermal-sensor-cells = <1>;
/* PWMs at 22.5 kHz frequency */
fan-0 {
--
2.56.0