Re: [PATCH v3 1/3] dt-bindings: usb: add rk3588 compatible to rockchip,dwc3

From: Sebastian Reichel
Date: Thu Oct 12 2023 - 08:31:02 EST


Hi,

On Tue, Oct 10, 2023 at 11:27:22AM -0500, Rob Herring wrote:
> [...]
> > +allOf:
> > + - $ref: snps,dwc3.yaml#
> > + - if:
> > + properties:
> > + compatible:
> > + contains:
> > + const: rockchip,rk3328-dwc3
> > + then:
> > + properties:
> > + clocks:
> > + minItems: 3
> > + maxItems: 4
> > + clock-names:
> > + minItems: 3
> > + items:
> > + - const: ref_clk
> > + - const: suspend_clk
> > + - const: bus_clk
> > + - const: grf_clk
>
> No need to list everything again. Just:
>
> contains:
> const: grf_clk

No, that does not work because 'grf_clk' is optional and by using
'contains: grf_clk' the check will complain if the list does not
contain 'grf_clk'.

> [...] more improvements suggested by Rob [...]

These look all fine to me and I fixed them up for v4.

> > + clock-names:
> > + minItems: 3
> > + items:
> > + - const: ref_clk
> > + - const: suspend_clk
> > + - const: bus_clk
> > + - const: utmi
> > + - const: pipe
>
> Again, can use 'contains' here. Where 'utmi' is in the list is already
> defined by the top-level schema.

Same issue as above. On RK3588 there is one USB3 controller, which
needs all 5 clocks and two controllers with just the first 3 clocks.
I initially had two different compatible strings to have fixed lists,
but Krzysztof asked to use only a single one.

-- Sebastian

Attachment: signature.asc
Description: PGP signature