fixed-partitions.yaml 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162
  1. # SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
  2. %YAML 1.2
  3. ---
  4. $id: http://devicetree.org/schemas/mtd/partitions/fixed-partitions.yaml#
  5. $schema: http://devicetree.org/meta-schemas/core.yaml#
  6. title: Fixed partitions
  7. description: |
  8. This binding can be used on platforms which have strong conventions about
  9. which portions of a flash are used for what purposes, but which don't use an
  10. on-flash partition table such as RedBoot.
  11. The partition table should be a node named "partitions". Partitions are then
  12. defined as subnodes.
  13. maintainers:
  14. - Rafał Miłecki <rafal@milecki.pl>
  15. properties:
  16. compatible:
  17. oneOf:
  18. - const: fixed-partitions
  19. - items:
  20. - const: sercomm,sc-partitions
  21. - const: fixed-partitions
  22. "#address-cells":
  23. enum: [ 1, 2 ]
  24. "#size-cells":
  25. enum: [ 1, 2 ]
  26. patternProperties:
  27. "@[0-9a-f]+$":
  28. $ref: partition.yaml#/$defs/partition-node
  29. required:
  30. - "#address-cells"
  31. - "#size-cells"
  32. # fixed-partitions can be nested
  33. allOf:
  34. - $ref: partition.yaml#
  35. unevaluatedProperties: false
  36. examples:
  37. - |
  38. partitions {
  39. compatible = "fixed-partitions";
  40. #address-cells = <1>;
  41. #size-cells = <1>;
  42. partition@0 {
  43. label = "u-boot";
  44. reg = <0x0000000 0x100000>;
  45. read-only;
  46. };
  47. uimage@100000 {
  48. reg = <0x0100000 0x200000>;
  49. compression = "lzma";
  50. };
  51. };
  52. - |
  53. partitions {
  54. compatible = "fixed-partitions";
  55. #address-cells = <1>;
  56. #size-cells = <2>;
  57. /* a 4 GiB partition */
  58. partition@0 {
  59. label = "filesystem";
  60. reg = <0x00000000 0x1 0x00000000>;
  61. linux,rootfs;
  62. };
  63. };
  64. - |
  65. partitions {
  66. compatible = "fixed-partitions";
  67. #address-cells = <2>;
  68. #size-cells = <2>;
  69. /* an 8 GiB partition */
  70. partition@0 {
  71. label = "filesystem #1";
  72. reg = <0x0 0x00000000 0x2 0x00000000>;
  73. };
  74. /* a 4 GiB partition */
  75. partition@200000000 {
  76. label = "filesystem #2";
  77. reg = <0x2 0x00000000 0x1 0x00000000>;
  78. };
  79. };
  80. - |
  81. partitions {
  82. compatible = "fixed-partitions";
  83. #address-cells = <1>;
  84. #size-cells = <1>;
  85. partition@0 {
  86. label = "bootloader";
  87. reg = <0x000000 0x100000>;
  88. read-only;
  89. };
  90. firmware@100000 {
  91. compatible = "brcm,trx";
  92. label = "firmware";
  93. reg = <0x100000 0xe00000>;
  94. };
  95. calibration@f00000 {
  96. compatible = "fixed-partitions";
  97. label = "calibration";
  98. reg = <0xf00000 0x100000>;
  99. #address-cells = <1>;
  100. #size-cells = <1>;
  101. partition@0 {
  102. label = "wifi0";
  103. reg = <0x000000 0x080000>;
  104. };
  105. partition@80000 {
  106. label = "wifi1";
  107. reg = <0x080000 0x080000>;
  108. };
  109. };
  110. };
  111. - |
  112. partitions {
  113. compatible = "sercomm,sc-partitions", "fixed-partitions";
  114. #address-cells = <1>;
  115. #size-cells = <1>;
  116. partition@0 {
  117. label = "u-boot";
  118. reg = <0x0 0x100000>;
  119. sercomm,scpart-id = <0>;
  120. read-only;
  121. };
  122. partition@100000 {
  123. label = "dynamic partition map";
  124. reg = <0x100000 0x100000>;
  125. sercomm,scpart-id = <1>;
  126. };
  127. partition@200000 {
  128. label = "Factory";
  129. reg = <0x200000 0x100000>;
  130. sercomm,scpart-id = <2>;
  131. read-only;
  132. };
  133. };