Texas Instruments GPMC Memory Controller

Schema identifier ($id): "http://devicetree.org/schemas/memory-controllers/ti,gpmc.yaml#"

Schema dialect ($schema): "http://devicetree.org/meta-schemas/core.yaml#"

Maintainers (maintainers): "Tony Lindgren <tony@atomide.com>", "Roger Quadros <rogerq@kernel.org>"

The GPMC is a unified memory controller dedicated for interfacing with external memory devices like - Asynchronous SRAM-like memories and ASICs - Asynchronous, synchronous, and page mode burst NOR flash - NAND flash - Pseudo-SRAM devices

Properties and child nodes (properties) #

compatible — required here #

Array item rules (items) #

Item 1

Allowed values (enum): "ti,am3352-gpmc", "ti,am64-gpmc", "ti,omap2420-gpmc", "ti,omap2430-gpmc", "ti,omap3430-gpmc", "ti,omap4430-gpmc"

reg — required here #

Minimum number of items (minItems): 1

Maximum number of items (maxItems): 2

reg-names — not listed as required here #

Array item rules (items) #

Item 1

Exact value (const): "cfg"

Item 2

Exact value (const): "data"

interrupts — not listed as required here #

Maximum number of items (maxItems): 1

clocks — not listed as required here #

Maximum number of items (maxItems): 1

Functional clock. Used for bus timing calculations and GPMC configuration.

clock-names — not listed as required here #

Array item rules (items) #

Item 1

Exact value (const): "fck"

power-domains — not listed as required here #

Maximum number of items (maxItems): 1

dmas — not listed as required here #

Array item rules (items) #

Item 1

DMA channel for GPMC NAND prefetch

dma-names — not listed as required here #

Array item rules (items) #

Item 1

Exact value (const): "rxtx"

#address-cells — required here #

true — No constraints added by this property rule.

#size-cells — required here #

true — No constraints added by this property rule.

gpmc,num-cs — required here #

maximum number of supported chip-select lines.

Shared schema rule ($ref): /schemas/types.yaml#/definitions/uint32

gpmc,num-waitpins — required here #

maximum number of supported wait pins.

Shared schema rule ($ref): /schemas/types.yaml#/definitions/uint32

ranges — not listed as required here #

Minimum number of items (minItems): 1

Must be set up to reflect the memory layout with four integer values for each chip-select line in use, <cs-number> 0 <physical address of mapping> <size>

Array item rules (items) #

Item 1

NAND bank 0

Item 2

NOR/SRAM bank 0

Item 3

NOR/SRAM bank 1

#interrupt-cells — not listed as required here #

Exact value (const): 2

interrupt-controller — not listed as required here #

The GPMC driver implements an interrupt controller for the NAND events "fifoevent" and "termcount" plus the rising/falling edges on the GPMC_WAIT pins. The interrupt number mapping is as follows 0 - NAND_fifoevent 1 - NAND_termcount 2 - GPMC_WAIT0 pin edge 3 - GPMC_WAIT1 pin edge, and so on.

#gpio-cells — not listed as required here #

Exact value (const): 2

gpio-controller — not listed as required here #

The GPMC driver implements a GPIO controller for the GPMC WAIT pins that can be used as general purpose inputs. 0 maps to GPMC_WAIT0 pin.

ti,hwmods — not listed as required here #

Name of the HWMOD associated with GPMC. This is for legacy omap2/3 platforms only.

Shared schema rule ($ref): /schemas/types.yaml#/definitions/string

Deprecated (deprecated): true

ti,no-idle-on-init — not listed as required here #

Prevent idling the module at init. This is for legacy omap2/3 platforms only.

Value type (type): "boolean"

Deprecated (deprecated): true

Properties matching a name pattern (patternProperties) #

@[0-7],[a-f0-9]+$ — name matches this regular expression #

Value type (type): "object"

The child device node represents the device connected to the GPMC bus. The device can be a NAND chip, SRAM device, NOR device or an ASIC.

Shared schema rule ($ref): ti,gpmc-child.yaml

Properties not matched by properties or patternProperties in this schema (additionalProperties) #

true

Allowed by this rule.

Required in this object (required): "compatible", "reg", "gpmc,num-cs", "gpmc,num-waitpins", "#address-cells", "#size-cells"

All of these rules must match (allOf) #

Rule 1 #

Condition (if) #

Properties and child nodes (properties)

compatible — not listed as required here

Rule for matching array elements (contains)

Exact value (const): "ti,am64-gpmc"

When the condition matches (then) #

Required in this object (required): "reg-names", "power-domains"

Properties not matched by properties or patternProperties in this schema (additionalProperties) #

false

Not allowed by this rule.

Examples (examples) #

#include <dt-bindings/interrupt-controller/arm-gic.h>
#include <dt-bindings/gpio/gpio.h>

gpmc: memory-controller@50000000 {
  compatible = "ti,am3352-gpmc";
  reg = <0x50000000 0x2000>;
  interrupts = <100>;
  clocks = <&l3s_clkctrl>;
  clock-names = "fck";
  dmas = <&edma 52 0>;
  dma-names = "rxtx";
  gpmc,num-cs = <8>;
  gpmc,num-waitpins = <2>;
  #address-cells = <2>;
  #size-cells = <1>;
  ranges = <0 0 0x08000000 0x10000000>; /* CS0 @addr 0x8000000, size 0x10000000 */
  interrupt-controller;
  #interrupt-cells = <2>;
  gpio-controller;
  #gpio-cells = <2>;

  nand@0,0 {
    compatible = "ti,omap2-nand";
    reg = <0 0 4>;
    interrupt-parent = <&gpmc>;
    interrupts = <0 IRQ_TYPE_NONE>, /* fifoevent */
                 <1 IRQ_TYPE_NONE>; /* termcount */
    ti,nand-xfer-type = "prefetch-dma";
    ti,nand-ecc-opt = "bch16";
    ti,elm-id = <&elm>;
    rb-gpios = <&gpmc 0 GPIO_ACTIVE_HIGH>; /* gpmc_wait0 pin */
  };
};

Source notes #

Annotations retained from the schema source

Line 1: SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)

Edit this page