11e25c5f5SBenjamin Gaignard# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
21e25c5f5SBenjamin Gaignard%YAML 1.2
31e25c5f5SBenjamin Gaignard---
41e25c5f5SBenjamin Gaignard$id: http://devicetree.org/schemas/mtd/st,stm32-fmc2-nand.yaml#
51e25c5f5SBenjamin Gaignard$schema: http://devicetree.org/meta-schemas/core.yaml#
61e25c5f5SBenjamin Gaignard
71e25c5f5SBenjamin Gaignardtitle: STMicroelectronics Flexible Memory Controller 2 (FMC2) Bindings
81e25c5f5SBenjamin Gaignard
91e25c5f5SBenjamin Gaignardmaintainers:
101e25c5f5SBenjamin Gaignard  - Christophe Kerello <christophe.kerello@st.com>
111e25c5f5SBenjamin Gaignard
121e25c5f5SBenjamin GaignardallOf:
131e25c5f5SBenjamin Gaignard  - $ref: "nand-controller.yaml#"
141e25c5f5SBenjamin Gaignard
151e25c5f5SBenjamin Gaignardproperties:
161e25c5f5SBenjamin Gaignard  compatible:
171e25c5f5SBenjamin Gaignard    const: st,stm32mp15-fmc2
181e25c5f5SBenjamin Gaignard
191e25c5f5SBenjamin Gaignard  reg:
201e25c5f5SBenjamin Gaignard    items:
211e25c5f5SBenjamin Gaignard      - description: Registers
221e25c5f5SBenjamin Gaignard      - description: Chip select 0 data
231e25c5f5SBenjamin Gaignard      - description: Chip select 0 command
241e25c5f5SBenjamin Gaignard      - description: Chip select 0 address space
251e25c5f5SBenjamin Gaignard      - description: Chip select 1 data
261e25c5f5SBenjamin Gaignard      - description: Chip select 1 command
271e25c5f5SBenjamin Gaignard      - description: Chip select 1 address space
281e25c5f5SBenjamin Gaignard
291e25c5f5SBenjamin Gaignard  interrupts:
301e25c5f5SBenjamin Gaignard    maxItems: 1
311e25c5f5SBenjamin Gaignard
321e25c5f5SBenjamin Gaignard  clocks:
331e25c5f5SBenjamin Gaignard    maxItems: 1
341e25c5f5SBenjamin Gaignard
351e25c5f5SBenjamin Gaignard  resets:
361e25c5f5SBenjamin Gaignard    maxItems: 1
371e25c5f5SBenjamin Gaignard
381e25c5f5SBenjamin Gaignard  dmas:
391e25c5f5SBenjamin Gaignard    items:
401e25c5f5SBenjamin Gaignard      - description: tx DMA channel
411e25c5f5SBenjamin Gaignard      - description: rx DMA channel
421e25c5f5SBenjamin Gaignard      - description: ecc DMA channel
431e25c5f5SBenjamin Gaignard
441e25c5f5SBenjamin Gaignard  dma-names:
451e25c5f5SBenjamin Gaignard    items:
461e25c5f5SBenjamin Gaignard      - const: tx
471e25c5f5SBenjamin Gaignard      - const: rx
481e25c5f5SBenjamin Gaignard      - const: ecc
491e25c5f5SBenjamin Gaignard
501e25c5f5SBenjamin GaignardpatternProperties:
511e25c5f5SBenjamin Gaignard  "^nand@[a-f0-9]$":
521e25c5f5SBenjamin Gaignard    type: object
531e25c5f5SBenjamin Gaignard    properties:
541e25c5f5SBenjamin Gaignard      nand-ecc-step-size:
551e25c5f5SBenjamin Gaignard        const: 512
561e25c5f5SBenjamin Gaignard
571e25c5f5SBenjamin Gaignard      nand-ecc-strength:
581e25c5f5SBenjamin Gaignard        enum: [1, 4 ,8 ]
591e25c5f5SBenjamin Gaignard
601e25c5f5SBenjamin Gaignardrequired:
611e25c5f5SBenjamin Gaignard  - compatible
621e25c5f5SBenjamin Gaignard  - reg
631e25c5f5SBenjamin Gaignard  - interrupts
641e25c5f5SBenjamin Gaignard  - clocks
651e25c5f5SBenjamin Gaignard
661e25c5f5SBenjamin Gaignardexamples:
671e25c5f5SBenjamin Gaignard  - |
681e25c5f5SBenjamin Gaignard    #include <dt-bindings/interrupt-controller/arm-gic.h>
691e25c5f5SBenjamin Gaignard    #include <dt-bindings/clock/stm32mp1-clks.h>
701e25c5f5SBenjamin Gaignard    #include <dt-bindings/reset/stm32mp1-resets.h>
711e25c5f5SBenjamin Gaignard    nand-controller@58002000 {
721e25c5f5SBenjamin Gaignard      compatible = "st,stm32mp15-fmc2";
731e25c5f5SBenjamin Gaignard      reg = <0x58002000 0x1000>,
741e25c5f5SBenjamin Gaignard            <0x80000000 0x1000>,
751e25c5f5SBenjamin Gaignard            <0x88010000 0x1000>,
761e25c5f5SBenjamin Gaignard            <0x88020000 0x1000>,
771e25c5f5SBenjamin Gaignard            <0x81000000 0x1000>,
781e25c5f5SBenjamin Gaignard            <0x89010000 0x1000>,
791e25c5f5SBenjamin Gaignard            <0x89020000 0x1000>;
801e25c5f5SBenjamin Gaignard            interrupts = <GIC_SPI 48 IRQ_TYPE_LEVEL_HIGH>;
811e25c5f5SBenjamin Gaignard            dmas = <&mdma1 20 0x10 0x12000a02 0x0 0x0>,
821e25c5f5SBenjamin Gaignard                   <&mdma1 20 0x10 0x12000a08 0x0 0x0>,
831e25c5f5SBenjamin Gaignard                   <&mdma1 21 0x10 0x12000a0a 0x0 0x0>;
841e25c5f5SBenjamin Gaignard            dma-names = "tx", "rx", "ecc";
851e25c5f5SBenjamin Gaignard            clocks = <&rcc FMC_K>;
861e25c5f5SBenjamin Gaignard            resets = <&rcc FMC_R>;
871e25c5f5SBenjamin Gaignard      #address-cells = <1>;
881e25c5f5SBenjamin Gaignard      #size-cells = <0>;
891e25c5f5SBenjamin Gaignard
901e25c5f5SBenjamin Gaignard      nand@0 {
911e25c5f5SBenjamin Gaignard        reg = <0>;
921e25c5f5SBenjamin Gaignard        nand-on-flash-bbt;
931e25c5f5SBenjamin Gaignard        #address-cells = <1>;
941e25c5f5SBenjamin Gaignard        #size-cells = <1>;
951e25c5f5SBenjamin Gaignard      };
961e25c5f5SBenjamin Gaignard    };
971e25c5f5SBenjamin Gaignard
981e25c5f5SBenjamin Gaignard...
99