Path: blob/main/sys/contrib/device-tree/Bindings/dma/fsl-imx-sdma.txt
48375 views
* Freescale Smart Direct Memory Access (SDMA) Controller for i.MX12Required properties:3- compatible : Should be one of4"fsl,imx25-sdma"5"fsl,imx31-sdma", "fsl,imx31-to1-sdma", "fsl,imx31-to2-sdma"6"fsl,imx35-sdma", "fsl,imx35-to1-sdma", "fsl,imx35-to2-sdma"7"fsl,imx51-sdma"8"fsl,imx53-sdma"9"fsl,imx6q-sdma"10"fsl,imx7d-sdma"11"fsl,imx6ul-sdma"12"fsl,imx8mq-sdma"13"fsl,imx8mm-sdma"14"fsl,imx8mn-sdma"15"fsl,imx8mp-sdma"16The -to variants should be preferred since they allow to determine the17correct ROM script addresses needed for the driver to work without additional18firmware.19- reg : Should contain SDMA registers location and length20- interrupts : Should contain SDMA interrupt21- #dma-cells : Must be <3>.22The first cell specifies the DMA request/event ID. See details below23about the second and third cell.24- fsl,sdma-ram-script-name : Should contain the full path of SDMA RAM25scripts firmware2627The second cell of dma phandle specifies the peripheral type of DMA transfer.28The full ID of peripheral types can be found below.2930ID transfer type31---------------------320 MCU domain SSI331 Shared SSI342 MMC353 SDHC364 MCU domain UART375 Shared UART386 FIRI397 MCU domain CSPI408 Shared CSPI419 SIM4210 ATA4311 CCM4412 External peripheral4513 Memory Stick Host Controller4614 Shared Memory Stick Host Controller4715 DSP4816 Memory4917 FIFO type Memory5018 SPDIF5119 IPU Memory5220 ASRC5321 ESAI5422 SSI Dual FIFO (needs firmware ver >= 2)5523 Shared ASRC5624 SAI5758The third cell specifies the transfer priority as below.5960ID transfer priority61-------------------------620 High631 Medium642 Low6566Optional properties:6768- gpr : The phandle to the General Purpose Register (GPR) node.69- fsl,sdma-event-remap : Register bits of sdma event remap, the format is70<reg shift val>.71reg is the GPR register offset.72shift is the bit position inside the GPR register.73val is the value of the bit (0 or 1).7475Examples:7677sdma@83fb0000 {78compatible = "fsl,imx51-sdma", "fsl,imx35-sdma";79reg = <0x83fb0000 0x4000>;80interrupts = <6>;81#dma-cells = <3>;82fsl,sdma-ram-script-name = "sdma-imx51.bin";83};8485DMA clients connected to the i.MX SDMA controller must use the format86described in the dma.txt file.8788Examples:8990ssi2: ssi@70014000 {91compatible = "fsl,imx51-ssi", "fsl,imx21-ssi";92reg = <0x70014000 0x4000>;93interrupts = <30>;94clocks = <&clks 49>;95dmas = <&sdma 24 1 0>,96<&sdma 25 1 0>;97dma-names = "rx", "tx";98fsl,fifo-depth = <15>;99};100101Using the fsl,sdma-event-remap property:102103If we want to use SDMA on the SAI1 port on a MX6SX:104105&sdma {106gpr = <&gpr>;107/* SDMA events remap for SAI1_RX and SAI1_TX */108fsl,sdma-event-remap = <0 15 1>, <0 16 1>;109};110111The fsl,sdma-event-remap property in this case has two values:112- <0 15 1> means that the offset is 0, so GPR0 is the register of the113SDMA remap. Bit 15 of GPR0 selects between UART4_RX and SAI1_RX.114Setting bit 15 to 1 selects SAI1_RX.115- <0 16 1> means that the offset is 0, so GPR0 is the register of the116SDMA remap. Bit 16 of GPR0 selects between UART4_TX and SAI1_TX.117Setting bit 16 to 1 selects SAI1_TX.118119120