244-v6.8-dt-bindings-arm-mediatek-move-ethsys-controller-conv.patch 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113
  1. From 94b0f301f6ee92f79a2fe2c655dfdbdfe2aec536 Mon Sep 17 00:00:00 2001
  2. From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= <[email protected]>
  3. Date: Sun, 19 Nov 2023 22:24:16 +0100
  4. Subject: [PATCH] dt-bindings: arm: mediatek: move ethsys controller & convert
  5. to DT schema
  6. MIME-Version: 1.0
  7. Content-Type: text/plain; charset=UTF-8
  8. Content-Transfer-Encoding: 8bit
  9. DT schema helps validating DTS files. Binding was moved to clock/ as
  10. this hardware is a clock provider. Example required a small fix for
  11. "reg" value (1 address cell + 1 size cell).
  12. Signed-off-by: Rafał Miłecki <[email protected]>
  13. Reviewed-by: Rob Herring <[email protected]>
  14. Link: https://lore.kernel.org/r/[email protected]
  15. Signed-off-by: Stephen Boyd <[email protected]>
  16. ---
  17. .../bindings/arm/mediatek/mediatek,ethsys.txt | 29 ----------
  18. .../bindings/clock/mediatek,ethsys.yaml | 54 +++++++++++++++++++
  19. 2 files changed, 54 insertions(+), 29 deletions(-)
  20. delete mode 100644 Documentation/devicetree/bindings/arm/mediatek/mediatek,ethsys.txt
  21. create mode 100644 Documentation/devicetree/bindings/clock/mediatek,ethsys.yaml
  22. --- a/Documentation/devicetree/bindings/arm/mediatek/mediatek,ethsys.txt
  23. +++ /dev/null
  24. @@ -1,29 +0,0 @@
  25. -Mediatek ethsys controller
  26. -============================
  27. -
  28. -The Mediatek ethsys controller provides various clocks to the system.
  29. -
  30. -Required Properties:
  31. -
  32. -- compatible: Should be:
  33. - - "mediatek,mt2701-ethsys", "syscon"
  34. - - "mediatek,mt7622-ethsys", "syscon"
  35. - - "mediatek,mt7623-ethsys", "mediatek,mt2701-ethsys", "syscon"
  36. - - "mediatek,mt7629-ethsys", "syscon"
  37. - - "mediatek,mt7981-ethsys", "syscon"
  38. - - "mediatek,mt7986-ethsys", "syscon"
  39. -- #clock-cells: Must be 1
  40. -- #reset-cells: Must be 1
  41. -
  42. -The ethsys controller uses the common clk binding from
  43. -Documentation/devicetree/bindings/clock/clock-bindings.txt
  44. -The available clocks are defined in dt-bindings/clock/mt*-clk.h.
  45. -
  46. -Example:
  47. -
  48. -ethsys: clock-controller@1b000000 {
  49. - compatible = "mediatek,mt2701-ethsys", "syscon";
  50. - reg = <0 0x1b000000 0 0x1000>;
  51. - #clock-cells = <1>;
  52. - #reset-cells = <1>;
  53. -};
  54. --- /dev/null
  55. +++ b/Documentation/devicetree/bindings/clock/mediatek,ethsys.yaml
  56. @@ -0,0 +1,54 @@
  57. +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
  58. +%YAML 1.2
  59. +---
  60. +$id: http://devicetree.org/schemas/clock/mediatek,ethsys.yaml#
  61. +$schema: http://devicetree.org/meta-schemas/core.yaml#
  62. +
  63. +title: Mediatek ethsys controller
  64. +
  65. +description:
  66. + The available clocks are defined in dt-bindings/clock/mt*-clk.h.
  67. +
  68. +maintainers:
  69. + - James Liao <[email protected]>
  70. +
  71. +properties:
  72. + compatible:
  73. + oneOf:
  74. + - items:
  75. + - enum:
  76. + - mediatek,mt2701-ethsys
  77. + - mediatek,mt7622-ethsys
  78. + - mediatek,mt7629-ethsys
  79. + - mediatek,mt7981-ethsys
  80. + - mediatek,mt7986-ethsys
  81. + - const: syscon
  82. + - items:
  83. + - const: mediatek,mt7623-ethsys
  84. + - const: mediatek,mt2701-ethsys
  85. + - const: syscon
  86. +
  87. + reg:
  88. + maxItems: 1
  89. +
  90. + "#clock-cells":
  91. + const: 1
  92. +
  93. + "#reset-cells":
  94. + const: 1
  95. +
  96. +required:
  97. + - reg
  98. + - "#clock-cells"
  99. + - "#reset-cells"
  100. +
  101. +additionalProperties: false
  102. +
  103. +examples:
  104. + - |
  105. + clock-controller@1b000000 {
  106. + compatible = "mediatek,mt2701-ethsys", "syscon";
  107. + reg = <0x1b000000 0x1000>;
  108. + #clock-cells = <1>;
  109. + #reset-cells = <1>;
  110. + };