Commit e43ddd0e authored by Krzysztof Kozlowski's avatar Krzysztof Kozlowski Committed by Vinod Koul
Browse files

dt-bindings: phy: qcom,sc7180-qmp-usb3-dp-phy: correct clocks per variants



Different variants of Qualcomm USB3 DP PHY take different clocks
(according to upstream DTS and Linux driver):

  sc7280-herobrine-crd.dtb: phy-wrapper@88e9000: clocks: [[43, 151], [39, 0], [43, 153]] is too short
  sc7280-herobrine-crd.dtb: phy-wrapper@88e9000: clock-names:1: 'cfg_ahb' was expected
  ...
  sm8250-hdk.dtb: phy@88e9000: clocks: [[46, 185], [44, 0], [46, 187]] is too short
  sm8250-hdk.dtb: phy@88e9000: clock-names:1: 'cfg_ahb' was expected

Signed-off-by: default avatarKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Acked-by: default avatarRob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20221225115944.55425-2-krzysztof.kozlowski@linaro.org


Signed-off-by: default avatarVinod Koul <vkoul@kernel.org>
parent 9fd4dcd9
Loading
Loading
Loading
Loading
+62 −10
Original line number Diff line number Diff line
@@ -51,18 +51,12 @@ properties:
  ranges: true

  clocks:
    items:
      - description: Phy aux clock.
      - description: Phy config clock.
      - description: 19.2 MHz ref clk.
      - description: Phy common block aux clock.
    minItems: 3
    maxItems: 4

  clock-names:
    items:
      - const: aux
      - const: cfg_ahb
      - const: ref
      - const: com_aux
    minItems: 3
    maxItems: 4

  power-domains:
    maxItems: 1
@@ -171,6 +165,64 @@ required:
  - vdda-phy-supply
  - vdda-pll-supply

allOf:
  - if:
      properties:
        compatible:
          enum:
            - qcom,sc7180-qmp-usb3-dp-phy
            - qcom,sdm845-qmp-usb3-dp-phy
    then:
      properties:
        clocks:
          items:
            - description: Phy aux clock
            - description: Phy config clock
            - description: 19.2 MHz ref clk
            - description: Phy common block aux clock
        clock-names:
          items:
            - const: aux
            - const: cfg_ahb
            - const: ref
            - const: com_aux

  - if:
      properties:
        compatible:
          enum:
            - qcom,sc8180x-qmp-usb3-dp-phy
    then:
      properties:
        clocks:
          items:
            - description: Phy aux clock
            - description: 19.2 MHz ref clk
            - description: Phy common block aux clock
        clock-names:
          items:
            - const: aux
            - const: ref
            - const: com_aux

  - if:
      properties:
        compatible:
          enum:
            - qcom,sm8250-qmp-usb3-dp-phy
    then:
      properties:
        clocks:
          items:
            - description: Phy aux clock
            - description: Board XO source
            - description: Phy common block aux clock
        clock-names:
          items:
            - const: aux
            - const: ref_clk_src
            - const: com_aux

additionalProperties: false

examples: