All of lore.kernel.org
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Nicolae-Daniel Deaconescu" <Nicolae-daniel.Deaconescu@analog.com>
Cc: devicetree@vger.kernel.org, robh@kernel.org, conor+dt@kernel.org
Subject: Re: [PATCH v2 4/5] dt-bindings: iio: adc: adi,ad7625: add LTC2387 and ADAQ2387x
Date: Wed, 04 Nov 2026 13:28:18 +0000	[thread overview]
Message-ID: <sashiko-outbox-197341@kernel.org> (raw)
In-Reply-To: <20261104132143.215581-5-Nicolae-daniel.Deaconescu@analog.com>

Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] dt-bindings: iio: adc: adi,ad7625: split LTC2387 and ADAQ2387x into separate schema
--

commit c29e24d5cf54c71037786f3f4fd74c43de8e27b1
Author: Sergiu Cuciurean <sergiu.cuciurean@analog.com>

dt-bindings: iio: adc: adi,ad7625: add LTC2387 and ADAQ2387x

This commit adds devicetree bindings for the LTC2387-16, LTC2387-18,
ADAQ23875, ADAQ23876, and ADAQ23878 ADCs to the existing adi,ad7625.yaml
schema. It defines their power supplies, PWM names, and configuration
properties alongside the existing AD762x and AD796x family bindings.

> diff --git a/Documentation/devicetree/bindings/iio/adc/adi,ad7625.yaml b/Documentation/devicetree/bindings/iio/adc/adi,ad7625.yaml
> index 8848562af28f2..dbdded88236ca 100644
> --- a/Documentation/devicetree/bindings/iio/adc/adi,ad7625.yaml
> +++ b/Documentation/devicetree/bindings/iio/adc/adi,ad7625.yaml
[ ... ]
> @@ -109,10 +159,6 @@ properties:
>  
>  required:
>    - compatible
> -  - vdd1-supply
> -  - vdd2-supply
> -  - vio-supply
> -  - clocks
>    - pwms
>    - pwm-names
>    - io-backends
> @@ -157,6 +203,111 @@ allOf:
>          - required: [ref-supply]
>          - required: [refin-supply]
>  
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - adi,ad7625
> +              - adi,ad7626
> +              - adi,ad7960
> +              - adi,ad7961
> +    then:
> +      properties:
> +        pwm-names:
> +          items:
> +            - const: cnv
> +            - const: clk_gate
> +        vdd-supply: false
> +        vddl-supply: false
> +        ovdd-supply: false
> +        vs-p-supply: false
> +        vs-n-supply: false
> +        adi,use-two-lanes: false
> +        adi,gain-milli: false
> +      required:
> +        - vdd1-supply
> +        - vdd2-supply
> +        - vio-supply
> +        - clocks
> +    else:
> +      # The LTC2387 and ADAQ parts have no EN pins and no clock to describe.
> +      properties:
> +        pwm-names:
> +          items:
> +            - const: cnv
> +            - const: clk
> +        vdd1-supply: false
> +        vdd2-supply: false
> +        clocks: false
> +        # REFIN is the bandgap output and the input of the reference buffer.
> +        # An external reference goes to REFBUF, through ref-supply.
> +        refin-supply: false
> +        en0-gpios: false
> +        en1-gpios: false
> +        en2-gpios: false
> +        en3-gpios: false
> +        adi,en0-always-on: false
> +        adi,en1-always-on: false
> +        adi,en2-always-on: false
> +        adi,en3-always-on: false
> +        adi,no-dco: false
> +      required:
> +        - vdd-supply
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - adi,ltc2387-16
> +              - adi,ltc2387-18
> +    then:
> +      properties:
> +        vio-supply: false
> +        vs-p-supply: false
> +        vs-n-supply: false
> +        adi,gain-milli: false
> +      required:
> +        - vddl-supply
> +        - ovdd-supply
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - adi,adaq23875
> +              - adi,adaq23876
> +              - adi,adaq23878
> +    then:
> +      properties:
> +        vddl-supply: false
> +        ovdd-supply: false
> +      required:
> +        - vio-supply
> +        - vs-p-supply
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            const: adi,adaq23875
> +    then:
> +      properties:
> +        adi,gain-milli: false
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - adi,adaq23876
> +              - adi,adaq23878
> +    then:
> +      required:
> +        - adi,gain-milli

[Severity: Low]
This isn't a bug, but since the LTC2387 and ADAQ2387x parts only share
compatible, pwms, io-backends, and optional ref-supply with the AD762x and
AD796x family (while even pwm-names differs on the second entry), combining
them into adi,ad7625.yaml requires removing the top-level required properties
and adding five if-then-else blocks under allOf to make nearly all supplies,
clocks, and device properties mutually exclusive.

Would it be cleaner to split the LTC2387 and ADAQ2387x parts into a separate
binding schema document rather than adding these conditionals to
adi,ad7625.yaml?

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261104132143.215581-1-Nicolae-daniel.Deaconescu@analog.com?part=4

  reply	other threads:[~2026-11-04 13:28 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-04 13:21 [PATCH v2 0/5] iio: adc: ad7625: add LTC2387 and ADAQ2387x support Nicolae-Daniel Deaconescu
2026-11-04 13:21 ` [PATCH v2 1/5] pwm: core: add pwm_get_waveform_step_might_sleep() Nicolae-Daniel Deaconescu
2026-11-04 19:51   ` Andy Shevchenko
2026-11-04 13:21 ` [PATCH v2 2/5] pwm: axi-pwmgen: report the waveform step Nicolae-Daniel Deaconescu
2026-11-04 13:21 ` [PATCH v2 3/5] iio: adc: ad7625: fix sampling frequency handling Nicolae-Daniel Deaconescu
2026-11-04 13:21 ` [PATCH v2 4/5] dt-bindings: iio: adc: adi,ad7625: add LTC2387 and ADAQ2387x Nicolae-Daniel Deaconescu
2026-11-04 13:28   ` sashiko-bot [this message]
2026-11-05  0:23   ` Conor Dooley
2026-11-04 13:21 ` [PATCH v2 5/5] iio: adc: ad7625: add LTC2387 and ADAQ2387x support Nicolae-Daniel Deaconescu
2026-11-04 20:22   ` Andy Shevchenko

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=sashiko-outbox-197341@kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=Nicolae-daniel.Deaconescu@analog.com \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=robh@kernel.org \
    --cc=sashiko-reviews@lists.linux.dev \
    /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.