0091-dt-bindings-usb-Add-StarFive-JH7110-USB-controller.patch 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135
  1. From 6a2392c96041d0599d33799a9aedbcdbfb4030b6 Mon Sep 17 00:00:00 2001
  2. From: Minda Chen <[email protected]>
  3. Date: Thu, 18 May 2023 19:27:48 +0800
  4. Subject: [PATCH 091/122] dt-bindings: usb: Add StarFive JH7110 USB controller
  5. StarFive JH7110 platforms USB have a wrapper module around
  6. the Cadence USBSS-DRD controller. Add binding information doc
  7. for that.
  8. Signed-off-by: Minda Chen <[email protected]>
  9. Reviewed-by: Peter Chen <[email protected]>
  10. Reviewed-by: Hal Feng <[email protected]>
  11. ---
  12. .../bindings/usb/starfive,jh7110-usb.yaml | 115 ++++++++++++++++++
  13. 1 file changed, 115 insertions(+)
  14. create mode 100644 Documentation/devicetree/bindings/usb/starfive,jh7110-usb.yaml
  15. --- /dev/null
  16. +++ b/Documentation/devicetree/bindings/usb/starfive,jh7110-usb.yaml
  17. @@ -0,0 +1,115 @@
  18. +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
  19. +%YAML 1.2
  20. +---
  21. +$id: http://devicetree.org/schemas/usb/starfive,jh7110-usb.yaml#
  22. +$schema: http://devicetree.org/meta-schemas/core.yaml#
  23. +
  24. +title: StarFive JH7110 wrapper module for the Cadence USBSS-DRD controller
  25. +
  26. +maintainers:
  27. + - Minda Chen <[email protected]>
  28. +
  29. +properties:
  30. + compatible:
  31. + const: starfive,jh7110-usb
  32. +
  33. + ranges: true
  34. +
  35. + starfive,stg-syscon:
  36. + $ref: /schemas/types.yaml#/definitions/phandle-array
  37. + items:
  38. + - items:
  39. + - description: phandle to System Register Controller stg_syscon node.
  40. + - description: dr mode register offset of STG_SYSCONSAIF__SYSCFG register for USB.
  41. + description:
  42. + The phandle to System Register Controller syscon node and the offset
  43. + of STG_SYSCONSAIF__SYSCFG register for USB.
  44. +
  45. + dr_mode:
  46. + enum: [host, otg, peripheral]
  47. +
  48. + "#address-cells":
  49. + enum: [1, 2]
  50. +
  51. + "#size-cells":
  52. + enum: [1, 2]
  53. +
  54. + clocks:
  55. + items:
  56. + - description: link power management clock
  57. + - description: standby clock
  58. + - description: APB clock
  59. + - description: AXI clock
  60. + - description: UTMI APB clock
  61. +
  62. + clock-names:
  63. + items:
  64. + - const: lpm
  65. + - const: stb
  66. + - const: apb
  67. + - const: axi
  68. + - const: utmi_apb
  69. +
  70. + resets:
  71. + items:
  72. + - description: Power up reset
  73. + - description: APB clock reset
  74. + - description: AXI clock reset
  75. + - description: UTMI APB clock reset
  76. +
  77. + reset-names:
  78. + items:
  79. + - const: pwrup
  80. + - const: apb
  81. + - const: axi
  82. + - const: utmi_apb
  83. +
  84. +patternProperties:
  85. + "^usb@[0-9a-f]+$":
  86. + $ref: cdns,usb3.yaml#
  87. + description: Required child node
  88. +
  89. +required:
  90. + - compatible
  91. + - ranges
  92. + - starfive,stg-syscon
  93. + - '#address-cells'
  94. + - '#size-cells'
  95. + - dr_mode
  96. + - clocks
  97. + - resets
  98. +
  99. +additionalProperties: false
  100. +
  101. +examples:
  102. + - |
  103. + usb@10100000 {
  104. + compatible = "starfive,jh7110-usb";
  105. + ranges = <0x0 0x10100000 0x100000>;
  106. + #address-cells = <1>;
  107. + #size-cells = <1>;
  108. + starfive,stg-syscon = <&stg_syscon 0x4>;
  109. + clocks = <&syscrg 4>,
  110. + <&stgcrg 5>,
  111. + <&stgcrg 1>,
  112. + <&stgcrg 3>,
  113. + <&stgcrg 2>;
  114. + clock-names = "lpm", "stb", "apb", "axi", "utmi_apb";
  115. + resets = <&stgcrg 10>,
  116. + <&stgcrg 8>,
  117. + <&stgcrg 7>,
  118. + <&stgcrg 9>;
  119. + reset-names = "pwrup", "apb", "axi", "utmi_apb";
  120. + dr_mode = "host";
  121. +
  122. + usb@0 {
  123. + compatible = "cdns,usb3";
  124. + reg = <0x0 0x10000>,
  125. + <0x10000 0x10000>,
  126. + <0x20000 0x10000>;
  127. + reg-names = "otg", "xhci", "dev";
  128. + interrupts = <100>, <108>, <110>;
  129. + interrupt-names = "host", "peripheral", "otg";
  130. + maximum-speed = "super-speed";
  131. + };
  132. + };