Message ID | 20240221080238.1615536-5-xu.yang_2@nxp.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | [RESEND,v6,1/9] dt-bindings: usb: usbmisc-imx: add fsl,imx8ulp-usbmisc compatible | expand |
On 21/02/2024 09:02, Xu Yang wrote: > Add restrictions for reg, interrupts, clock and clock-names properties > for imx Socs. > > Signed-off-by: Xu Yang <xu.yang_2@nxp.com> > > --- > Changes in v4: > - new patch since v3's discussion > - split the reg, interrupts, clock and clock-names properties into Duplicated patchset, discussion is in other thread. To make it explicit that it should not be applied: NAK Best regards, Krzysztof
diff --git a/Documentation/devicetree/bindings/usb/ci-hdrc-usb2-imx.yaml b/Documentation/devicetree/bindings/usb/ci-hdrc-usb2-imx.yaml index 2ec62f564bf5..20bb048938ff 100644 --- a/Documentation/devicetree/bindings/usb/ci-hdrc-usb2-imx.yaml +++ b/Documentation/devicetree/bindings/usb/ci-hdrc-usb2-imx.yaml @@ -49,11 +49,63 @@ properties: - const: fsl,imx6ul-usb - const: fsl,imx27-usb + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + allOf: - $ref: ci-hdrc-usb2.yaml# + # imx27 Soc needs three clocks + - if: + properties: + compatible: + const: fsl,imx27-usb + then: + properties: + clocks: + minItems: 3 + maxItems: 3 + clock-names: + items: + - const: ipg + - const: ahb + - const: per + else: + # imx25 and imx35 Soc need three clocks + if: + properties: + compatible: + contains: + enum: + - fsl,imx25-usb + - fsl,imx35-usb + then: + properties: + clocks: + minItems: 3 + maxItems: 3 + clock-names: + items: + - const: ipg + - const: ahb + - const: per + else: + # other imx Socs only need one clock + properties: + clocks: + minItems: 1 + maxItems: 1 + clock-names: + minItems: 1 + maxItems: 1 + required: - compatible + - reg + - interrupts unevaluatedProperties: false
Add restrictions for reg, interrupts, clock and clock-names properties for imx Socs. Signed-off-by: Xu Yang <xu.yang_2@nxp.com> --- Changes in v4: - new patch since v3's discussion - split the reg, interrupts, clock and clock-names properties into common part and device-specific Changes in v5: - keep common property unchanged - make if-then more readable - remove non imx part Changes in v6: - new patch based on ci-hdrc-usb2-imx.yaml --- .../bindings/usb/ci-hdrc-usb2-imx.yaml | 52 +++++++++++++++++++ 1 file changed, 52 insertions(+)