Re: [PATCH v4 2/5] dt-bindings: thermal: generic-adc: Document #io-channel-cells
From: Luca Weiss
Date: Tue Dec 01 2026 - 10:43:44 EST
Hi Rob,
On Thu Nov 19, 2026 at 10:13 AM CET, Luca Weiss wrote:
> On Wed Nov 18, 2026 at 5:42 PM CET, Rob Herring wrote:
>> On Tue, Nov 17, 2026 at 09:23:12AM +0100, Luca Weiss wrote:
>>> Document the property to allow using this sensor with io-channels.
>>>
>>> This means that the output of generic-adc-thermal can be used as an
>>> input into a different node.
>>>
>>> As a specific example, generic-adc-thermal takes in an ADC io-channel in
>>> Volt, outputs temperature in degC, which can then be consumed by a fuel
>>> gauge driver to provide the battery temperature readings to user space.
>>
>> But this is already a thermal-sensor provider, why wouldn't the fuel
>> gauge use that provider?
>
> thermal-sensors = <&my_generic_adc_thermal>; could work, yes, but IIO is
> way more flexible and can support the required use case very well.
>
> From what I can see no device binding (or Linux) uses thermal-sensors
> apart from thermal zones, so actually doing this for another device
> feels like re-inventing the wheel when IIO already exists.
>
> Please also see the cover letter from the RFC[0] under "1. Do not
> implement IIO device in generic-adc-thermal"
>
> [0] https://lore.kernel.org/linux-arm-msm/20251010-bat-temp-adc-v1-0-d51ec895dac6@xxxxxxxxxxxxx/
Do you have any more feedback for this?
Regards
Luca