264 lines · yaml
1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)2# Copyright (C) 2020 Texas Instruments Incorporated3# Author: Peter Ujfalusi <peter.ujfalusi@ti.com>4%YAML 1.25---6$id: http://devicetree.org/schemas/dma/ti/k3-bcdma.yaml#7$schema: http://devicetree.org/meta-schemas/core.yaml#8 9title: Texas Instruments K3 DMSS BCDMA10 11maintainers:12 - Peter Ujfalusi <peter.ujfalusi@gmail.com>13 14description: |15 The Block Copy DMA (BCDMA) is intended to perform similar functions as the TR16 mode channels of K3 UDMA-P.17 BCDMA includes block copy channels and Split channels.18 19 Block copy channels mainly used for memory to memory transfers, but with20 optional triggers a block copy channel can service peripherals by accessing21 directly to memory mapped registers or area.22 23 Split channels can be used to service PSI-L based peripherals.24 The peripherals can be PSI-L native or legacy, non PSI-L native peripherals25 with PDMAs. PDMA is tasked to act as a bridge between the PSI-L fabric and the26 legacy peripheral.27 28 PDMAs can be configured via BCDMA split channel's peer registers to match with29 the configuration of the legacy peripheral.30 31properties:32 compatible:33 enum:34 - ti,am62a-dmss-bcdma-csirx35 - ti,am64-dmss-bcdma36 - ti,j721s2-dmss-bcdma-csi37 38 reg:39 minItems: 340 maxItems: 941 42 reg-names:43 minItems: 344 maxItems: 945 46 "#dma-cells":47 const: 348 description: |49 cell 1: type of the BCDMA channel to be used to service the peripheral:50 0 - split channel51 1 - block copy channel using global trigger 152 2 - block copy channel using global trigger 253 3 - block copy channel using local trigger54 55 cell 2: parameter for the channel:56 if cell 1 is 0 (split channel):57 PSI-L thread ID of the remote (to BCDMA) end.58 Valid ranges for thread ID depends on the data movement direction:59 for source thread IDs (rx): 0 - 0x7fff60 for destination thread IDs (tx): 0x8000 - 0xffff61 62 Please refer to the device documentation for the PSI-L thread map and63 also the PSI-L peripheral chapter for the correct thread ID.64 if cell 1 is 1 or 2 (block copy channel using global trigger):65 Unused, ignored66 67 The trigger must be configured for the channel externally to BCDMA,68 channels using global triggers should not be requested directly, but69 via DMA event router.70 if cell 1 is 3 (block copy channel using local trigger):71 bchan number of the locally triggered channel72 73 cell 3: ASEL value for the channel74 75 msi-parent: true76 77 power-domains:78 description:79 Power domain if available80 maxItems: 181 82 ti,asel:83 $ref: /schemas/types.yaml#/definitions/uint3284 description: ASEL value for non slave channels85 86 ti,sci-rm-range-bchan:87 $ref: /schemas/types.yaml#/definitions/uint32-array88 description: |89 Array of BCDMA block-copy channel resource subtypes for resource90 allocation for this host91 minItems: 192 # Should be enough93 maxItems: 25594 items:95 maximum: 0x3f96 97 ti,sci-rm-range-tchan:98 $ref: /schemas/types.yaml#/definitions/uint32-array99 description: |100 Array of BCDMA split tx channel resource subtypes for resource allocation101 for this host102 minItems: 1103 # Should be enough104 maxItems: 255105 items:106 maximum: 0x3f107 108 ti,sci-rm-range-rchan:109 $ref: /schemas/types.yaml#/definitions/uint32-array110 description: |111 Array of BCDMA split rx channel resource subtypes for resource allocation112 for this host113 minItems: 1114 # Should be enough115 maxItems: 255116 items:117 maximum: 0x3f118 119required:120 - compatible121 - "#dma-cells"122 - reg123 - reg-names124 - msi-parent125 - ti,sci126 - ti,sci-dev-id127 - ti,sci-rm-range-rchan128 129allOf:130 - $ref: /schemas/dma/dma-controller.yaml#131 - $ref: /schemas/arm/keystone/ti,k3-sci-common.yaml#132 133 - if:134 properties:135 compatible:136 contains:137 const: ti,am62a-dmss-bcdma-csirx138 then:139 properties:140 ti,sci-rm-range-bchan: false141 ti,sci-rm-range-tchan: false142 143 reg:144 items:145 - description: BCDMA Control /Status Registers region146 - description: RX Channel Realtime Registers region147 - description: Ring Realtime Registers region148 149 reg-names:150 items:151 - const: gcfg152 - const: rchanrt153 - const: ringrt154 155 required:156 - power-domains157 158 - if:159 properties:160 compatible:161 contains:162 const: ti,am64-dmss-bcdma163 then:164 properties:165 reg:166 minItems: 5167 items:168 - description: BCDMA Control /Status Registers region169 - description: Block Copy Channel Realtime Registers region170 - description: RX Channel Realtime Registers region171 - description: TX Channel Realtime Registers region172 - description: Ring Realtime Registers region173 - description: Ring Configuration Registers region174 - description: TX Channel Configuration Registers region175 - description: RX Channel Configuration Registers region176 - description: Block Copy Channel Configuration Registers region177 178 reg-names:179 minItems: 5180 items:181 - const: gcfg182 - const: bchanrt183 - const: rchanrt184 - const: tchanrt185 - const: ringrt186 - const: ring187 - const: tchan188 - const: rchan189 - const: bchan190 191 required:192 - ti,sci-rm-range-bchan193 - ti,sci-rm-range-tchan194 195 - if:196 properties:197 compatible:198 contains:199 const: ti,j721s2-dmss-bcdma-csi200 then:201 properties:202 ti,sci-rm-range-bchan: false203 204 reg:205 items:206 - description: BCDMA Control /Status Registers region207 - description: RX Channel Realtime Registers region208 - description: TX Channel Realtime Registers region209 - description: Ring Realtime Registers region210 211 reg-names:212 items:213 - const: gcfg214 - const: rchanrt215 - const: tchanrt216 - const: ringrt217 218 required:219 - ti,sci-rm-range-tchan220 221unevaluatedProperties: false222 223examples:224 - |+225 cbass_main {226 #address-cells = <2>;227 #size-cells = <2>;228 229 main_dmss {230 compatible = "simple-mfd";231 #address-cells = <2>;232 #size-cells = <2>;233 dma-ranges;234 ranges;235 236 ti,sci-dev-id = <25>;237 238 main_bcdma: dma-controller@485c0100 {239 compatible = "ti,am64-dmss-bcdma";240 241 reg = <0x0 0x485c0100 0x0 0x100>,242 <0x0 0x4c000000 0x0 0x20000>,243 <0x0 0x4a820000 0x0 0x20000>,244 <0x0 0x4aa40000 0x0 0x20000>,245 <0x0 0x4bc00000 0x0 0x100000>,246 <0x0 0x48600000 0x0 0x8000>,247 <0x0 0x484a4000 0x0 0x2000>,248 <0x0 0x484c2000 0x0 0x2000>,249 <0x0 0x48420000 0x0 0x2000>;250 reg-names = "gcfg", "bchanrt", "rchanrt", "tchanrt", "ringrt",251 "ring", "tchan", "rchan", "bchan";252 msi-parent = <&inta_main_dmss>;253 #dma-cells = <3>;254 255 ti,sci = <&dmsc>;256 ti,sci-dev-id = <26>;257 258 ti,sci-rm-range-bchan = <0x20>; /* BLOCK_COPY_CHAN */259 ti,sci-rm-range-rchan = <0x21>; /* SPLIT_TR_RX_CHAN */260 ti,sci-rm-range-tchan = <0x22>; /* SPLIT_TR_TX_CHAN */261 };262 };263 };264