1*5956d97fSEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2*5956d97fSEmmanuel Vadot%YAML 1.2 3*5956d97fSEmmanuel Vadot--- 4*5956d97fSEmmanuel Vadot$id: http://devicetree.org/schemas/memory-controllers/arm,pl353-smc.yaml# 5*5956d97fSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml# 6*5956d97fSEmmanuel Vadot 7*5956d97fSEmmanuel Vadottitle: ARM PL353 Static Memory Controller (SMC) device-tree bindings 8*5956d97fSEmmanuel Vadot 9*5956d97fSEmmanuel Vadotmaintainers: 10*5956d97fSEmmanuel Vadot - Miquel Raynal <miquel.raynal@bootlin.com> 11*5956d97fSEmmanuel Vadot - Naga Sureshkumar Relli <naga.sureshkumar.relli@xilinx.com> 12*5956d97fSEmmanuel Vadot 13*5956d97fSEmmanuel Vadotdescription: 14*5956d97fSEmmanuel Vadot The PL353 Static Memory Controller is a bus where you can connect two kinds 15*5956d97fSEmmanuel Vadot of memory interfaces, which are NAND and memory mapped interfaces (such as 16*5956d97fSEmmanuel Vadot SRAM or NOR). 17*5956d97fSEmmanuel Vadot 18*5956d97fSEmmanuel Vadot# We need a select here so we don't match all nodes with 'arm,primecell' 19*5956d97fSEmmanuel Vadotselect: 20*5956d97fSEmmanuel Vadot properties: 21*5956d97fSEmmanuel Vadot compatible: 22*5956d97fSEmmanuel Vadot contains: 23*5956d97fSEmmanuel Vadot const: arm,pl353-smc-r2p1 24*5956d97fSEmmanuel Vadot required: 25*5956d97fSEmmanuel Vadot - compatible 26*5956d97fSEmmanuel Vadot 27*5956d97fSEmmanuel Vadotproperties: 28*5956d97fSEmmanuel Vadot $nodename: 29*5956d97fSEmmanuel Vadot pattern: "^memory-controller@[0-9a-f]+$" 30*5956d97fSEmmanuel Vadot 31*5956d97fSEmmanuel Vadot compatible: 32*5956d97fSEmmanuel Vadot items: 33*5956d97fSEmmanuel Vadot - const: arm,pl353-smc-r2p1 34*5956d97fSEmmanuel Vadot - const: arm,primecell 35*5956d97fSEmmanuel Vadot 36*5956d97fSEmmanuel Vadot "#address-cells": 37*5956d97fSEmmanuel Vadot const: 2 38*5956d97fSEmmanuel Vadot 39*5956d97fSEmmanuel Vadot "#size-cells": 40*5956d97fSEmmanuel Vadot const: 1 41*5956d97fSEmmanuel Vadot 42*5956d97fSEmmanuel Vadot reg: 43*5956d97fSEmmanuel Vadot items: 44*5956d97fSEmmanuel Vadot - description: 45*5956d97fSEmmanuel Vadot Configuration registers for the host and sub-controllers. 46*5956d97fSEmmanuel Vadot The three chip select regions are defined in 'ranges'. 47*5956d97fSEmmanuel Vadot 48*5956d97fSEmmanuel Vadot clocks: 49*5956d97fSEmmanuel Vadot items: 50*5956d97fSEmmanuel Vadot - description: clock for the memory device bus 51*5956d97fSEmmanuel Vadot - description: main clock of the SMC 52*5956d97fSEmmanuel Vadot 53*5956d97fSEmmanuel Vadot clock-names: 54*5956d97fSEmmanuel Vadot items: 55*5956d97fSEmmanuel Vadot - const: memclk 56*5956d97fSEmmanuel Vadot - const: apb_pclk 57*5956d97fSEmmanuel Vadot 58*5956d97fSEmmanuel Vadot ranges: 59*5956d97fSEmmanuel Vadot minItems: 1 60*5956d97fSEmmanuel Vadot description: | 61*5956d97fSEmmanuel Vadot Memory bus areas for interacting with the devices. Reflects 62*5956d97fSEmmanuel Vadot the memory layout with four integer values following: 63*5956d97fSEmmanuel Vadot <cs-number> 0 <offset> <size> 64*5956d97fSEmmanuel Vadot items: 65*5956d97fSEmmanuel Vadot - description: NAND bank 0 66*5956d97fSEmmanuel Vadot - description: NOR/SRAM bank 0 67*5956d97fSEmmanuel Vadot - description: NOR/SRAM bank 1 68*5956d97fSEmmanuel Vadot 69*5956d97fSEmmanuel Vadot interrupts: true 70*5956d97fSEmmanuel Vadot 71*5956d97fSEmmanuel VadotpatternProperties: 72*5956d97fSEmmanuel Vadot "@[0-3],[a-f0-9]+$": 73*5956d97fSEmmanuel Vadot type: object 74*5956d97fSEmmanuel Vadot description: | 75*5956d97fSEmmanuel Vadot The child device node represents the controller connected to the SMC 76*5956d97fSEmmanuel Vadot bus. The controller can be a NAND controller or a pair of any memory 77*5956d97fSEmmanuel Vadot mapped controllers such as NOR and SRAM controllers. 78*5956d97fSEmmanuel Vadot 79*5956d97fSEmmanuel Vadot properties: 80*5956d97fSEmmanuel Vadot compatible: 81*5956d97fSEmmanuel Vadot description: 82*5956d97fSEmmanuel Vadot Compatible of memory controller. 83*5956d97fSEmmanuel Vadot 84*5956d97fSEmmanuel Vadot reg: 85*5956d97fSEmmanuel Vadot items: 86*5956d97fSEmmanuel Vadot - items: 87*5956d97fSEmmanuel Vadot - description: | 88*5956d97fSEmmanuel Vadot Chip-select ID, as in the parent range property. 89*5956d97fSEmmanuel Vadot minimum: 0 90*5956d97fSEmmanuel Vadot maximum: 2 91*5956d97fSEmmanuel Vadot - description: | 92*5956d97fSEmmanuel Vadot Offset of the memory region requested by the device. 93*5956d97fSEmmanuel Vadot - description: | 94*5956d97fSEmmanuel Vadot Length of the memory region requested by the device. 95*5956d97fSEmmanuel Vadot 96*5956d97fSEmmanuel Vadot required: 97*5956d97fSEmmanuel Vadot - compatible 98*5956d97fSEmmanuel Vadot - reg 99*5956d97fSEmmanuel Vadot 100*5956d97fSEmmanuel Vadotrequired: 101*5956d97fSEmmanuel Vadot - compatible 102*5956d97fSEmmanuel Vadot - reg 103*5956d97fSEmmanuel Vadot - clock-names 104*5956d97fSEmmanuel Vadot - clocks 105*5956d97fSEmmanuel Vadot - "#address-cells" 106*5956d97fSEmmanuel Vadot - "#size-cells" 107*5956d97fSEmmanuel Vadot - ranges 108*5956d97fSEmmanuel Vadot 109*5956d97fSEmmanuel VadotadditionalProperties: false 110*5956d97fSEmmanuel Vadot 111*5956d97fSEmmanuel Vadotexamples: 112*5956d97fSEmmanuel Vadot - | 113*5956d97fSEmmanuel Vadot smcc: memory-controller@e000e000 { 114*5956d97fSEmmanuel Vadot compatible = "arm,pl353-smc-r2p1", "arm,primecell"; 115*5956d97fSEmmanuel Vadot reg = <0xe000e000 0x0001000>; 116*5956d97fSEmmanuel Vadot clock-names = "memclk", "apb_pclk"; 117*5956d97fSEmmanuel Vadot clocks = <&clkc 11>, <&clkc 44>; 118*5956d97fSEmmanuel Vadot ranges = <0x0 0x0 0xe1000000 0x1000000 /* Nand CS region */ 119*5956d97fSEmmanuel Vadot 0x1 0x0 0xe2000000 0x2000000 /* SRAM/NOR CS0 region */ 120*5956d97fSEmmanuel Vadot 0x2 0x0 0xe4000000 0x2000000>; /* SRAM/NOR CS1 region */ 121*5956d97fSEmmanuel Vadot #address-cells = <2>; 122*5956d97fSEmmanuel Vadot #size-cells = <1>; 123*5956d97fSEmmanuel Vadot 124*5956d97fSEmmanuel Vadot nfc0: nand-controller@0,0 { 125*5956d97fSEmmanuel Vadot compatible = "arm,pl353-nand-r2p1"; 126*5956d97fSEmmanuel Vadot reg = <0 0 0x1000000>; 127*5956d97fSEmmanuel Vadot #address-cells = <1>; 128*5956d97fSEmmanuel Vadot #size-cells = <0>; 129*5956d97fSEmmanuel Vadot }; 130*5956d97fSEmmanuel Vadot }; 131