Re: [PATCH v13 1/3] dt-bindings: adc: add AD7173

Jonathan Cameron
2024-02-24T18:30:09Z

On Tue, 20 Feb 2024 18:52:37 +0000
Conor Dooley <conor@kernel.org> wrote:

> On Tue, Feb 20, 2024 at 11:43:38AM +0200, Dumitru Ceclan wrote:
>
> > + interrupts:
> > + minItems: 1
> > + description: |
>
> > +
> > + interrupt-names:
> > + minItems: 1
> > + items:
> > + - const: rdy
> > + - const: err
>
> I noticed that for minItems == 1, the rdy interrupt is required and err
> is the optional one.
>
> With that in mind, you can simplify the interrupts description so that
> it describes the interrupts separately:
>
> interrupts:
> minItems:
> items:
> - description:
> Ready: multiplexed with SPI data out. While SPI CS is low,
> can be used to indicate the completion of a conversion.
>
> - description:
> Error: The three error bits in the status register (ADC_ERROR, CRC_ERROR,
> and REG_ERROR) are OR'ed, inverted, and mapped to the ERROR pin. Therefore,
> the ERROR pin indicates that an error has occurred.
>
> Otherwise, I think everything has been sorted out?
>
> Reviewed-by: Conor Dooley <conor.dooley@microchip.com>

This ordering may bite us in the future. Someone will build a board
with err as only one wired. But meh, it will be a binding relaxation needed
so I'm not that bothered by that.
>
> Cheers,
> Conor.