i2c: imx: add DMA support for freescale i2c driver
authorYao Yuan <yao.yuan@freescale.com>
Tue, 18 Nov 2014 10:31:06 +0000 (18:31 +0800)
committerWolfram Sang <wsa@the-dreams.de>
Tue, 18 Nov 2014 15:01:27 +0000 (16:01 +0100)
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>
Documentation/devicetree/bindings/i2c/i2c-imx.txt
drivers/i2c/busses/i2c-imx.c

index 4a8513e..52d37fd 100644 (file)
@@ -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:
 
@@ -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";
+};
Simple merge