^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1) # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 2) %YAML 1.2
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 3) ---
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 4) $id: http://devicetree.org/schemas/mtd/gpmi-nand.yaml#
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 5) $schema: http://devicetree.org/meta-schemas/core.yaml#
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 6)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 7) title: Freescale General-Purpose Media Interface (GPMI) binding
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 8)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 9) maintainers:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10) - Han Xu <han.xu@nxp.com>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12) allOf:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) - $ref: "nand-controller.yaml"
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) description: |
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) The GPMI nand controller provides an interface to control the NAND
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) flash chips. The device tree may optionally contain sub-nodes
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) describing partitions of the address space. See partition.txt for
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) more detail.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) properties:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22) compatible:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) oneOf:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24) - enum:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) - fsl,imx23-gpmi-nand
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) - fsl,imx28-gpmi-nand
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) - fsl,imx6q-gpmi-nand
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) - fsl,imx6sx-gpmi-nand
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) - fsl,imx7d-gpmi-nand
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) - items:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31) - enum:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32) - fsl,imx8mm-gpmi-nand
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) - fsl,imx8mn-gpmi-nand
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34) - const: fsl,imx7d-gpmi-nand
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) reg:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) items:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38) - description: Address and length of gpmi block.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 39) - description: Address and length of bch block.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 40)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 41) reg-names:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 42) items:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 43) - const: gpmi-nand
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 44) - const: bch
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 45)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 46) interrupts:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 47) maxItems: 1
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 48)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 49) interrupt-names:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 50) const: bch
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 51)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 52) dmas:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 53) maxItems: 1
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 54)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 55) dma-names:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 56) const: rx-tx
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 57)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 58) clocks:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 59) minItems: 1
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 60) maxItems: 5
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 61) items:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 62) - description: SoC gpmi io clock
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 63) - description: SoC gpmi apb clock
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 64) - description: SoC gpmi bch clock
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 65) - description: SoC gpmi bch apb clock
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 66) - description: SoC per1 bch clock
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 67)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 68) clock-names:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 69) minItems: 1
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 70) maxItems: 5
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 71) items:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 72) - const: gpmi_io
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 73) - const: gpmi_apb
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 74) - const: gpmi_bch
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 75) - const: gpmi_bch_apb
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 76) - const: per1_bch
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 77)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 78) fsl,use-minimum-ecc:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 79) type: boolean
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 80) description: |
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 81) Protect this NAND flash with the minimum ECC strength required.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 82) The required ECC strength is automatically discoverable for some
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 83) flash (e.g., according to the ONFI standard). However, note that
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 84) if this strength is not discoverable or this property is not enabled,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 85) the software may chooses an implementation-defined ECC scheme.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 86)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 87) fsl,no-blockmark-swap:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 88) type: boolean
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 89) description: |
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 90) Don't swap the bad block marker from the OOB area with the byte in
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 91) the data area but rely on the flash based BBT for identifying bad blocks.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 92) NOTE: this is only valid in conjunction with 'nand-on-flash-bbt'.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 93) WARNING: on i.MX28 blockmark swapping cannot be disabled for the BootROM
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 94) in the FCB. Thus, partitions written from Linux with this feature turned
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 95) on may not be accessible by the BootROM code.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 96)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 97) required:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 98) - compatible
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 99) - reg
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 100) - reg-names
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 101) - interrupts
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 102) - interrupt-names
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 103) - clocks
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 104) - clock-names
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 105) - dmas
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 106) - dma-names
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 107)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 108) unevaluatedProperties: false
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 109)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 110) examples:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 111) - |
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 112) nand-controller@8000c000 {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 113) #address-cells = <1>;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 114) #size-cells = <0>;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 115) compatible = "fsl,imx28-gpmi-nand";
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 116) reg = <0x8000c000 0x2000>, <0x8000a000 0x2000>;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 117) reg-names = "gpmi-nand", "bch";
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 118) interrupts = <41>;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 119) interrupt-names = "bch";
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 120) clocks = <&clks 50>;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 121) clock-names = "gpmi_io";
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 122) dmas = <&dma_apbh 4>;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 123) dma-names = "rx-tx";
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 124) };