ingenic,nand.yaml 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139
  1. # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
  2. %YAML 1.2
  3. ---
  4. $id: http://devicetree.org/schemas/mtd/ingenic,nand.yaml#
  5. $schema: http://devicetree.org/meta-schemas/core.yaml#
  6. title: Ingenic SoCs NAND controller
  7. maintainers:
  8. - Paul Cercueil <paul@crapouillou.net>
  9. allOf:
  10. - $ref: nand-controller.yaml#
  11. - $ref: /schemas/memory-controllers/ingenic,nemc-peripherals.yaml#
  12. properties:
  13. compatible:
  14. enum:
  15. - ingenic,jz4740-nand
  16. - ingenic,jz4725b-nand
  17. - ingenic,jz4780-nand
  18. reg:
  19. items:
  20. - description: Bank number, offset and size of first attached NAND chip
  21. - description: Bank number, offset and size of second attached NAND chip
  22. - description: Bank number, offset and size of third attached NAND chip
  23. - description: Bank number, offset and size of fourth attached NAND chip
  24. minItems: 1
  25. ecc-engine: true
  26. partitions:
  27. type: object
  28. deprecated: true
  29. description:
  30. Node containing description of fixed partitions.
  31. patternProperties:
  32. "^nand@[a-f0-9]$":
  33. type: object
  34. $ref: raw-nand-chip.yaml
  35. properties:
  36. rb-gpios:
  37. description: GPIO specifier for the busy pin.
  38. maxItems: 1
  39. wp-gpios:
  40. description: GPIO specifier for the write-protect pin.
  41. maxItems: 1
  42. unevaluatedProperties: false
  43. required:
  44. - compatible
  45. - reg
  46. unevaluatedProperties: false
  47. examples:
  48. - |
  49. #include <dt-bindings/clock/ingenic,jz4780-cgu.h>
  50. memory-controller@13410000 {
  51. compatible = "ingenic,jz4780-nemc";
  52. reg = <0x13410000 0x10000>;
  53. #address-cells = <2>;
  54. #size-cells = <1>;
  55. ranges = <1 0 0x1b000000 0x1000000>,
  56. <2 0 0x1a000000 0x1000000>,
  57. <3 0 0x19000000 0x1000000>,
  58. <4 0 0x18000000 0x1000000>,
  59. <5 0 0x17000000 0x1000000>,
  60. <6 0 0x16000000 0x1000000>;
  61. clocks = <&cgu JZ4780_CLK_NEMC>;
  62. nand-controller@1 {
  63. compatible = "ingenic,jz4780-nand";
  64. reg = <1 0 0x1000000>;
  65. #address-cells = <1>;
  66. #size-cells = <0>;
  67. ecc-engine = <&bch>;
  68. ingenic,nemc-tAS = <10>;
  69. ingenic,nemc-tAH = <5>;
  70. ingenic,nemc-tBP = <10>;
  71. ingenic,nemc-tAW = <15>;
  72. ingenic,nemc-tSTRV = <100>;
  73. pinctrl-names = "default";
  74. pinctrl-0 = <&pins_nemc>;
  75. nand@1 {
  76. reg = <1>;
  77. nand-ecc-step-size = <1024>;
  78. nand-ecc-strength = <24>;
  79. nand-ecc-mode = "hw";
  80. nand-on-flash-bbt;
  81. pinctrl-names = "default";
  82. pinctrl-0 = <&pins_nemc_cs1>;
  83. partitions {
  84. compatible = "fixed-partitions";
  85. #address-cells = <2>;
  86. #size-cells = <2>;
  87. partition@0 {
  88. label = "u-boot-spl";
  89. reg = <0x0 0x0 0x0 0x800000>;
  90. };
  91. partition@800000 {
  92. label = "u-boot";
  93. reg = <0x0 0x800000 0x0 0x200000>;
  94. };
  95. partition@a00000 {
  96. label = "u-boot-env";
  97. reg = <0x0 0xa00000 0x0 0x200000>;
  98. };
  99. partition@c00000 {
  100. label = "boot";
  101. reg = <0x0 0xc00000 0x0 0x4000000>;
  102. };
  103. partition@4c00000 {
  104. label = "system";
  105. reg = <0x0 0x4c00000 0x1 0xfb400000>;
  106. };
  107. };
  108. };
  109. };
  110. };