1
0
Fork 0
alistair23-linux/Documentation/devicetree/bindings/dma/fsl-edma-v3.txt

83 lines
3.2 KiB
Plaintext
Raw Permalink Normal View History

* Freescale enhanced Direct Memory Access(eDMA-v3) Controller
The eDMA-v3 controller is inherited from FSL eDMA, and firstly is intergrated
on Freescale i.MX8QM SOC chip. The eDMA channels have multiplex capability by
programmble memory-mapped registers. Specific DMA request source has fixed channel.
* eDMA Controller
Required properties:
- compatible :
- "fsl,imx8qm-edma" for eDMA used similar to that on i.MX8QM SoC
- "fsl,imx8qm-adma" for audio eDMA used on i.MX8QM
- reg : Specifies base physical address(s) and size of the eDMA channel registers.
Each eDMA channel has separated register's address and size.
- interrupts : A list of interrupt-specifiers, each channel has one interrupt.
MLK-16327-1: dma: fsl-edma-v3: make exclusive channel name for all edma channels Since there are multi edmav3 instances on i.mx8, every edma channel name is better unique.But so far, all edma channel name is 'edma-channel(id)- tx',thus some edma channels which share the same channel id but different edma instance will show the same channel name in kernel and this is not friendly to debug in kernel. Now the edma channel name(interrupt-names property) is define in dts as below: "edmaX-chanX-Xx" | | |---> receive/transmit, r or t | |---> channel id, the max number is 32 |---> edma controller instance, 0, 1, 2,..etc and get below correct name with 'cat /proc/interrupts': 43: 0 0 0 0 GICv3 466 Level edma0-chan8-rx 44: 0 0 0 0 GICv3 467 Level edma0-chan9-tx 45: 79 0 0 0 GICv3 468 Level edma0-chan10-rx 46: 311 0 0 0 GICv3 469 Level edma0-chan11-tx 47: 0 0 0 0 GICv3 470 Level edma0-chan12-rx 48: 0 0 0 0 GICv3 471 Level edma0-chan13-tx 49: 0 0 0 0 GICv3 472 Level edma0-chan14-rx 50: 0 0 0 0 GICv3 473 Level edma0-chan15-tx 51: 0 0 0 0 GICv3 406 Level edma2-chan0-tx 52: 0 0 0 0 GICv3 407 Level edma2-chan1-tx 53: 0 0 0 0 GICv3 408 Level edma2-chan2-tx 54: 0 0 0 0 GICv3 409 Level edma2-chan3-tx 55: 0 0 0 0 GICv3 410 Level edma2-chan4-tx 56: 0 0 0 0 GICv3 411 Level edma2-chan5-tx 57: 0 0 0 0 GICv3 442 Level edma2-chan6-rx, edma2-chan7-tx Signed-off-by: Robin Gong <yibin.gong@nxp.com> Reviewed-by: Shengjiu Wang <shengjiu.wang@nxp.com> (cherry picked from commit af8e197a92c9c024ec4fbfcf543d744e81748773)
2017-08-30 04:51:16 -06:00
- interrupt-names : Should contain below template:
"edmaX-chanX-Xx"
| | |---> receive/transmit, r or t
| |---> channel id, the max number is 32
|---> edma controller instance, 0, 1, 2,..etc
- #dma-cells : Must be <3>.
The 1st cell specifies the channel ID.
The 2nd cell specifies the channel priority.
The 3rd cell specifies the channel attributes which include below:
BIT(0): transmit or receive:
0: transmit, 1: receive.
BIT(1): local or remote access:
0: local, 1: remote.
BIT(2): dualfifo case or not(only in Audio cyclic now):
0: not dual fifo case, 1: dualfifo case.
See the SoC's reference manual for all the supported request sources.
- dma-channels : Number of channels supported by the controller
- power-domains: Power domains for edma channel used.
- power-domain-names: Power domains name for edma channel used.
Examples:
edma0: dma-controller@40018000 {
compatible = "fsl,imx8qm-edma";
reg = <0x0 0x5a2c0000 0x0 0x10000>, /* channel12 UART0 rx */
<0x0 0x5a2d0000 0x0 0x10000>, /* channel13 UART0 tx */
<0x0 0x5a2e0000 0x0 0x10000>, /* channel14 UART1 rx */
<0x0 0x5a2f0000 0x0 0x10000>; /* channel15 UART1 tx */
#dma-cells = <3>;
dma-channels = <4>;
interrupts = <GIC_SPI 434 IRQ_TYPE_LEVEL_HIGH>,
<GIC_SPI 435 IRQ_TYPE_LEVEL_HIGH>,
<GIC_SPI 436 IRQ_TYPE_LEVEL_HIGH>,
<GIC_SPI 437 IRQ_TYPE_LEVEL_HIGH>;
MLK-16327-1: dma: fsl-edma-v3: make exclusive channel name for all edma channels Since there are multi edmav3 instances on i.mx8, every edma channel name is better unique.But so far, all edma channel name is 'edma-channel(id)- tx',thus some edma channels which share the same channel id but different edma instance will show the same channel name in kernel and this is not friendly to debug in kernel. Now the edma channel name(interrupt-names property) is define in dts as below: "edmaX-chanX-Xx" | | |---> receive/transmit, r or t | |---> channel id, the max number is 32 |---> edma controller instance, 0, 1, 2,..etc and get below correct name with 'cat /proc/interrupts': 43: 0 0 0 0 GICv3 466 Level edma0-chan8-rx 44: 0 0 0 0 GICv3 467 Level edma0-chan9-tx 45: 79 0 0 0 GICv3 468 Level edma0-chan10-rx 46: 311 0 0 0 GICv3 469 Level edma0-chan11-tx 47: 0 0 0 0 GICv3 470 Level edma0-chan12-rx 48: 0 0 0 0 GICv3 471 Level edma0-chan13-tx 49: 0 0 0 0 GICv3 472 Level edma0-chan14-rx 50: 0 0 0 0 GICv3 473 Level edma0-chan15-tx 51: 0 0 0 0 GICv3 406 Level edma2-chan0-tx 52: 0 0 0 0 GICv3 407 Level edma2-chan1-tx 53: 0 0 0 0 GICv3 408 Level edma2-chan2-tx 54: 0 0 0 0 GICv3 409 Level edma2-chan3-tx 55: 0 0 0 0 GICv3 410 Level edma2-chan4-tx 56: 0 0 0 0 GICv3 411 Level edma2-chan5-tx 57: 0 0 0 0 GICv3 442 Level edma2-chan6-rx, edma2-chan7-tx Signed-off-by: Robin Gong <yibin.gong@nxp.com> Reviewed-by: Shengjiu Wang <shengjiu.wang@nxp.com> (cherry picked from commit af8e197a92c9c024ec4fbfcf543d744e81748773)
2017-08-30 04:51:16 -06:00
interrupt-names = "edma0-chan12-rx", "edma0-chan13-tx",
"edma0-chan14-rx", "edma0-chan15-tx";
power-domains = <&pd IMX_SC_R_DMA_0_CH12>,
<&pd IMX_SC_R_DMA_0_CH13>,
<&pd IMX_SC_R_DMA_0_CH14>,
<&pd IMX_SC_R_DMA_0_CH15>;
power-domain-names = "edma0-chan12", "edma0-chan13",
"edma0-chan14", "edma0-chan15";
status = "okay";
};
* DMA clients
DMA client drivers that uses the DMA function must use the format described
in the dma.txt file, using a three-cell specifier for each channel: the 1st
specifies the channel number, the 2nd specifies the priority, and the 3rd
specifies the channel type is for transmit or receive: 0: transmit, 1: receive.
Examples:
lpuart1: serial@5a070000 {
compatible = "fsl,imx8qm-lpuart";
reg = <0x0 0x5a070000 0x0 0x1000>;
interrupts = <GIC_SPI 226 IRQ_TYPE_LEVEL_HIGH>;
interrupt-parent = <&gic>;
clocks = <&clk IMX8QM_UART1_CLK>;
clock-names = "ipg";
assigned-clock-names = <&clk IMX8QM_UART1_CLK>;
assigned-clock-rates = <80000000>;
power-domains = <&pd IMX_SC_R_UART_1>,
power-domain-names = "uart";
dma-names = "tx","rx";
dmas = <&edma0 15 0 0>,
<&edma0 14 0 1>;
status = "disabled";
};