[PATCH v4 1/2] dt-bindings: thermal: generic-adc: Add optional io-channel-cells property

Svyatoslav Ryhel posted 2 patches 11 months ago
There is a newer version of this series
[PATCH v4 1/2] dt-bindings: thermal: generic-adc: Add optional io-channel-cells property
Posted by Svyatoslav Ryhel 11 months ago
This implements a mechanism to derive temperature values from an existing
ADC IIO channel, effectively creating a temperature IIO channel. This
approach avoids adding a new sensor and its associated conversion table,
while providing IIO-based temperature data for devices that may not utilize
hwmon.

Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
---
 .../devicetree/bindings/thermal/generic-adc-thermal.yaml      | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/Documentation/devicetree/bindings/thermal/generic-adc-thermal.yaml b/Documentation/devicetree/bindings/thermal/generic-adc-thermal.yaml
index 12e6418dc24d..4bc2cff0593c 100644
--- a/Documentation/devicetree/bindings/thermal/generic-adc-thermal.yaml
+++ b/Documentation/devicetree/bindings/thermal/generic-adc-thermal.yaml
@@ -30,6 +30,9 @@ properties:
   io-channel-names:
     const: sensor-channel
 
+  '#io-channel-cells':
+    const: 1
+
   temperature-lookup-table:
     description: |
       Lookup table to map the relation between ADC value and temperature.
@@ -60,6 +63,7 @@ examples:
         #thermal-sensor-cells = <0>;
         io-channels = <&ads1015 1>;
         io-channel-names = "sensor-channel";
+        #io-channel-cells = <1>;
         temperature-lookup-table = <
               (-40000) 2578
               (-39000) 2577
-- 
2.43.0
Re: [PATCH v4 1/2] dt-bindings: thermal: generic-adc: Add optional io-channel-cells property
Posted by Krzysztof Kozlowski 11 months ago
On 10/03/2025 08:56, Svyatoslav Ryhel wrote:
> This implements a mechanism to derive temperature values from an existing
> ADC IIO channel, effectively creating a temperature IIO channel. This
> approach avoids adding a new sensor and its associated conversion table,
> while providing IIO-based temperature data for devices that may not utilize
> hwmon.
> 

You got comments from Rob few days ago to which you did not respond.
Instead you decided to send next version, which hides the previous
unresolved discussion.

This patch does not look necessary based on earlier discussion.

Best regards,
Krzysztof
Re: [PATCH v4 1/2] dt-bindings: thermal: generic-adc: Add optional io-channel-cells property
Posted by Svyatoslav Ryhel 11 months ago
вт, 11 бер. 2025 р. о 10:20 Krzysztof Kozlowski <krzk@kernel.org> пише:
>
> On 10/03/2025 08:56, Svyatoslav Ryhel wrote:
> > This implements a mechanism to derive temperature values from an existing
> > ADC IIO channel, effectively creating a temperature IIO channel. This
> > approach avoids adding a new sensor and its associated conversion table,
> > while providing IIO-based temperature data for devices that may not utilize
> > hwmon.
> >
>
> You got comments from Rob few days ago to which you did not respond.
> Instead you decided to send next version, which hides the previous
> unresolved discussion.
>
> This patch does not look necessary based on earlier discussion.
>

ok, I will remove this schema change