summaryrefslogtreecommitdiffstats
path: root/Documentation/devicetree/bindings/mtd/gpmi-nand.yaml
blob: 354cb63feea3e761361662dd50aca3dbb8d888ee (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/mtd/gpmi-nand.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title:  Freescale General-Purpose Media Interface (GPMI) binding

maintainers:
  - Han Xu <han.xu@nxp.com>

allOf:
  - $ref: "nand-controller.yaml"

description: |
  The GPMI nand controller provides an interface to control the NAND
  flash chips. The device tree may optionally contain sub-nodes
  describing partitions of the address space. See partition.txt for
  more detail.

properties:
  compatible:
    enum:
      - fsl,imx23-gpmi-nand
      - fsl,imx28-gpmi-nand
      - fsl,imx6q-gpmi-nand
      - fsl,imx6sx-gpmi-nand
      - fsl,imx7d-gpmi-nand

  reg:
    items:
      - description: Address and length of gpmi block.
      - description: Address and length of bch block.

  reg-names:
    items:
      - const: gpmi-nand
      - const: bch

  interrupts:
    maxItems: 1

  interrupt-names:
    const: bch

  dmas:
    maxItems: 1

  dma-names:
    const: rx-tx

  clocks:
    minItems: 1
    maxItems: 5
    items:
      - description: SoC gpmi io clock
      - description: SoC gpmi apb clock
      - description: SoC gpmi bch clock
      - description: SoC gpmi bch apb clock
      - description: SoC per1 bch clock

  clock-names:
    minItems: 1
    maxItems: 5
    items:
      - const: gpmi_io
      - const: gpmi_apb
      - const: gpmi_bch
      - const: gpmi_bch_apb
      - const: per1_bch

  fsl,use-minimum-ecc:
    type: boolean
    description: |
      Protect this NAND flash with the minimum ECC strength required.
      The required ECC strength is automatically discoverable for some
      flash (e.g., according to the ONFI standard). However, note that
      if this strength is not discoverable or this property is not enabled,
      the software may chooses an implementation-defined ECC scheme.

  fsl,no-blockmark-swap:
    type: boolean
    description: |
      Don't swap the bad block marker from the OOB area with the byte in
      the data area but rely on the flash based BBT for identifying bad blocks.
      NOTE: this is only valid in conjunction with 'nand-on-flash-bbt'.
      WARNING: on i.MX28 blockmark swapping cannot be disabled for the BootROM
      in the FCB. Thus, partitions written from Linux with this feature turned
      on may not be accessible by the BootROM code.

required:
  - compatible
  - reg
  - reg-names
  - interrupts
  - interrupt-names
  - clocks
  - clock-names
  - dmas
  - dma-names

unevaluatedProperties: false

examples:
  - |
    nand-controller@8000c000 {
        #address-cells = <1>;
        #size-cells = <0>;
        compatible = "fsl,imx28-gpmi-nand";
        reg = <0x8000c000 0x2000>, <0x8000a000 0x2000>;
        reg-names = "gpmi-nand", "bch";
        interrupts = <41>;
        interrupt-names = "bch";
        clocks = <&clks 50>;
        clock-names = "gpmi_io";
        dmas = <&dma_apbh 4>;
        dma-names = "rx-tx";
    };