On Sat, May 09, 2026 at 10:17:52AM +0000, Antony Kurniawan Soemardi wrote:
> Some Qualcomm SoCs such as apq8064 and msm8960 require a third "fs"
> clock in addition to "iface" and "core", needed to propagate resets
> through the controller and wrapper logic. Later SoCs such as msm8974
> dropped this requirement and only use two clocks.
> 
> Signed-off-by: Antony Kurniawan Soemardi <[email protected]>
> ---
> This patch updates the ci-hdrc-usb2 binding to allow up to 3 clocks for
> qcom,ci-hdrc, to accommodate Qualcomm SoCs that require an additional
> "fs" clock for reset propagation.
> 
> This is a prerequisite for the following patch series currently under
> review:
>   - ARM: dts: qcom: apq8064: Fix USB controller clocks [1]
>   - ARM: dts: qcom: msm8960: add RPM clock controller and fix USB
>     clocks [2]
> 
> Without this binding change, those series produce dtbs_check errors
> due to the 3-clock entries in their respective device tree sources.
> 
> [1] 
> https://lore.kernel.org/all/[email protected]/
> [2] 
> https://lore.kernel.org/all/[email protected]/
> ---
>  .../devicetree/bindings/usb/ci-hdrc-usb2.yaml      | 29 
> ++++++++++++++++------
>  1 file changed, 21 insertions(+), 8 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/usb/ci-hdrc-usb2.yaml 
> b/Documentation/devicetree/bindings/usb/ci-hdrc-usb2.yaml
> index 691d6cf02c27..5d18d47efaed 100644
> --- a/Documentation/devicetree/bindings/usb/ci-hdrc-usb2.yaml
> +++ b/Documentation/devicetree/bindings/usb/ci-hdrc-usb2.yaml
> @@ -43,14 +43,6 @@ properties:
>                - nxp,s32g3-usb
>            - const: nxp,s32g2-usb
>  
> -  clocks:
> -    minItems: 1
> -    maxItems: 2
> -
> -  clock-names:
> -    minItems: 1
> -    maxItems: 2
> -

You MUST NOT remove properties from top-level. See writing bindings and
writing schema docs.

>    operating-points-v2:
>      description: A phandle to the OPP table containing the performance 
> states.
>      $ref: /schemas/types.yaml#/definitions/phandle
> @@ -91,6 +83,27 @@ allOf:
>    - $ref: chipidea,usb2-common.yaml#
>    - $ref: usb-hcd.yaml#
>    - $ref: usb-drd.yaml#
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            const: qcom,ci-hdrc
> +    then:
> +      properties:
> +        clocks:
> +          minItems: 1
> +          maxItems: 3

List the items instead.

> +        clock-names:
> +          minItems: 1
> +          maxItems: 3

No, names cannot be flexible. Neither clocks can, BTW, but that's
problem of existing binding. You need to list the items.


> +    else:
> +      properties:
> +        clocks:
> +          minItems: 1
> +          maxItems: 2
> +        clock-names:
> +          minItems: 1
> +          maxItems: 2

This part is fine.

Best regards,
Krzysztof


Reply via email to