406-v5.13-0003-dt-bindings-mtd-Document-use-of-nvmem-cells-compatib.patch 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117
  1. From 377aa0135dc8489312edd3184d143ce3a89ff7ee Mon Sep 17 00:00:00 2001
  2. From: Ansuel Smith <[email protected]>
  3. Date: Fri, 12 Mar 2021 07:28:21 +0100
  4. Subject: [PATCH] dt-bindings: mtd: Document use of nvmem-cells compatible
  5. Document nvmem-cells compatible used to treat mtd partitions as a
  6. nvmem provider.
  7. Signed-off-by: Ansuel Smith <[email protected]>
  8. Reviewed-by: Rob Herring <[email protected]>
  9. ---
  10. .../bindings/mtd/partitions/nvmem-cells.yaml | 99 +++++++++++++++++++
  11. 1 file changed, 99 insertions(+)
  12. create mode 100644 Documentation/devicetree/bindings/mtd/partitions/nvmem-cells.yaml
  13. --- /dev/null
  14. +++ b/Documentation/devicetree/bindings/mtd/partitions/nvmem-cells.yaml
  15. @@ -0,0 +1,99 @@
  16. +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
  17. +%YAML 1.2
  18. +---
  19. +$id: http://devicetree.org/schemas/mtd/partitions/nvmem-cells.yaml#
  20. +$schema: http://devicetree.org/meta-schemas/core.yaml#
  21. +
  22. +title: Nvmem cells
  23. +
  24. +description: |
  25. + Any partition containing the compatible "nvmem-cells" will register as a
  26. + nvmem provider.
  27. + Each direct subnodes represents a nvmem cell following the nvmem binding.
  28. + Nvmem binding to declare nvmem-cells can be found in:
  29. + Documentation/devicetree/bindings/nvmem/nvmem.yaml
  30. +
  31. +maintainers:
  32. + - Ansuel Smith <[email protected]>
  33. +
  34. +allOf:
  35. + - $ref: /schemas/nvmem/nvmem.yaml#
  36. +
  37. +properties:
  38. + compatible:
  39. + const: nvmem-cells
  40. +
  41. +required:
  42. + - compatible
  43. +
  44. +additionalProperties: true
  45. +
  46. +examples:
  47. + - |
  48. + partitions {
  49. + compatible = "fixed-partitions";
  50. + #address-cells = <1>;
  51. + #size-cells = <1>;
  52. +
  53. + /* ... */
  54. +
  55. + };
  56. + art: art@1200000 {
  57. + compatible = "nvmem-cells";
  58. + reg = <0x1200000 0x0140000>;
  59. + label = "art";
  60. + read-only;
  61. + #address-cells = <1>;
  62. + #size-cells = <1>;
  63. +
  64. + macaddr_gmac1: macaddr_gmac1@0 {
  65. + reg = <0x0 0x6>;
  66. + };
  67. +
  68. + macaddr_gmac2: macaddr_gmac2@6 {
  69. + reg = <0x6 0x6>;
  70. + };
  71. +
  72. + pre_cal_24g: pre_cal_24g@1000 {
  73. + reg = <0x1000 0x2f20>;
  74. + };
  75. +
  76. + pre_cal_5g: pre_cal_5g@5000{
  77. + reg = <0x5000 0x2f20>;
  78. + };
  79. + };
  80. + - |
  81. + partitions {
  82. + compatible = "fixed-partitions";
  83. + #address-cells = <1>;
  84. + #size-cells = <1>;
  85. +
  86. + partition@0 {
  87. + label = "bootloader";
  88. + reg = <0x000000 0x100000>;
  89. + read-only;
  90. + };
  91. +
  92. + firmware@100000 {
  93. + compatible = "brcm,trx";
  94. + label = "firmware";
  95. + reg = <0x100000 0xe00000>;
  96. + };
  97. +
  98. + calibration@f00000 {
  99. + compatible = "nvmem-cells";
  100. + label = "calibration";
  101. + reg = <0xf00000 0x100000>;
  102. + ranges = <0 0xf00000 0x100000>;
  103. + #address-cells = <1>;
  104. + #size-cells = <1>;
  105. +
  106. + wifi0@0 {
  107. + reg = <0x000000 0x080000>;
  108. + };
  109. +
  110. + wifi1@80000 {
  111. + reg = <0x080000 0x080000>;
  112. + };
  113. + };
  114. + };