Skip to content

Commit

Permalink
i2c: imx: add DMA support for freescale i2c driver
Browse files Browse the repository at this point in the history
Add dma support for i2c. This function depend on DMA driver.
You can turn on it by write both the dmas and dma-name properties in dts node.
DMA is optional, even DMA request unsuccessfully, i2c can also work well.

Signed-off-by: Yuan Yao <yao.yuan@freescale.com>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
  • Loading branch information
Yao Yuan authored and Wolfram Sang committed Nov 18, 2014
1 parent 2fbed51 commit ce1a788
Show file tree
Hide file tree
Showing 2 changed files with 344 additions and 2 deletions.
11 changes: 11 additions & 0 deletions Documentation/devicetree/bindings/i2c/i2c-imx.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ Required properties:
Optional properties:
- clock-frequency : Constains desired I2C/HS-I2C bus clock frequency in Hz.
The absence of the propoerty indicates the default frequency 100 kHz.
- dmas: A list of two dma specifiers, one for each entry in dma-names.
- dma-names: should contain "tx" and "rx".

Examples:

Expand All @@ -26,3 +28,12 @@ i2c@70038000 { /* HS-I2C on i.MX51 */
interrupts = <64>;
clock-frequency = <400000>;
};

i2c0: i2c@40066000 { /* i2c0 on vf610 */
compatible = "fsl,vf610-i2c";
reg = <0x40066000 0x1000>;
interrupts =<0 71 0x04>;
dmas = <&edma0 0 50>,
<&edma0 0 51>;
dma-names = "rx","tx";
};
Loading

0 comments on commit ce1a788

Please sign in to comment.