[PATCH 1/2] dt-bindings: misc: atmel,at91-ssc: Convert to YAML format

Conor Dooley conor at kernel.org
Wed Jan 29 09:44:56 PST 2025


On Wed, Jan 29, 2025 at 03:28:23PM +0200, Andrei Simion wrote:
> Hi,
> 
> Thank you for the review.
> 
> I will place this in: Documentation/devicetree/bindings/sound/
> because the SSC it is used only for Audio.
> 
> >
> > Missing dai-cells. Old binding said 0, now you say anything...
> >
> > Missing required block
> >
> >> +allOf:
> >> +  - $ref: ../sound/dai-common.yaml#
> >
> > Full path, so /schemas/
> >
> >> +  - if:
> >> +      properties:
> >> +        compatible:
> >> +          contains:
> >> +            enum:
> >> +              - atmel,at91sam9g45-ssc
> >> +    then:
> >> +      required:
> >> +        - compatible
> >> +        - reg
> >> +        - interrupts
> >> +        - dmas
> >> +        - dma-names
> >
> > So only dmas?
> >
> >> +        - clocks
> >> +        - clock-names
> >> +    else:
> >> +      required:
> >> +        - compatible
> >> +        - reg
> >> +        - interrupts
> >> +        - clocks
> >> +        - clock-names
> >
> > Drop entire required:
> >
> 
> I have a question:
> 
> 1) The old binding said if "atmel,at91sam9g45-ssc": add dmas and DMA-names to the list:
> 	- compatible, reg, interrupts, clock-names, clocks
>    Why do you ask: "drop entire required"?

The bits that are required in both cases can be set outside the
conditional, so you can do something like

if:
  foo
then:
  required:
    - dmas
    - dma-names

required:
  - compatible
  - reg
  - interrupts
  - clocks
  - clock-names

which I think captures all of what you're trying to do in the quote
above.

>    I intended to set the required through a conditional.
>     case 1) dma transfer
>     case 2) pdc transfer

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 228 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20250129/8d8556de/attachment.sig>


More information about the linux-arm-kernel mailing list