All of lore.kernel.org
 help / color / mirror / Atom feed
From: Rob Herring <robh@kernel.org>
To: Svyatoslav Ryhel <clamor95@gmail.com>
Cc: "Rafael J. Wysocki" <rafael@kernel.org>,
	Daniel Lezcano <daniel.lezcano@linaro.org>,
	Zhang Rui <rui.zhang@intel.com>,
	Lukasz Luba <lukasz.luba@arm.com>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Laxman Dewangan <ldewangan@nvidia.com>,
	linux-pm@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 1/2] dt-bindings: thermal: generic-adc: Add optional io-channel-cells property
Date: Fri, 21 Feb 2025 15:13:01 -0600	[thread overview]
Message-ID: <20250221211301.GA83357-robh@kernel.org> (raw)
In-Reply-To: <20250219082817.56339-2-clamor95@gmail.com>

On Wed, Feb 19, 2025 at 10:28:16AM +0200, Svyatoslav Ryhel wrote:
> Since device is a thermal sensor it needs '#io-channel-cells' to allow
> exposure of thermal data via IIO means.

This looks odd. The consumer is also a producer? What in DT would be the 
2nd consumer. If you don't have a consumer in the DT, then you don't 
need '#io-channel-cells'.

I would like to see Jonathan's buy in on this.

> 
> 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

You have to document what is in the cells.

> +
>    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
> 

  reply	other threads:[~2025-02-21 21:13 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-19  8:28 [PATCH v2 0/2] thermal: thermal-generic-adc: add temp sensor function Svyatoslav Ryhel
2025-02-19  8:28 ` [PATCH v2 1/2] dt-bindings: thermal: generic-adc: Add optional io-channel-cells property Svyatoslav Ryhel
2025-02-21 21:13   ` Rob Herring [this message]
2025-02-22  7:12     ` Svyatoslav Ryhel
2025-02-19  8:28 ` [PATCH v2 2/2] thermal: thermal-generic-adc: add temperature sensor channel Svyatoslav Ryhel
2025-02-28 13:11   ` Lukasz Luba
2025-02-28 13:22     ` Svyatoslav Ryhel
2025-03-03 10:53       ` Lukasz Luba
2025-03-03 11:08         ` Svyatoslav Ryhel

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250221211301.GA83357-robh@kernel.org \
    --to=robh@kernel.org \
    --cc=clamor95@gmail.com \
    --cc=conor+dt@kernel.org \
    --cc=daniel.lezcano@linaro.org \
    --cc=devicetree@vger.kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=ldewangan@nvidia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=lukasz.luba@arm.com \
    --cc=rafael@kernel.org \
    --cc=rui.zhang@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.