]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
ENGR00139247-4 ARM: add APBH-DMA arch code for imx6q
authorHuang Shijie <b32955@freescale.com>
Fri, 22 Jul 2011 02:28:03 +0000 (10:28 +0800)
committerOliver Wendt <ow@karo-electronics.de>
Mon, 30 Sep 2013 12:09:27 +0000 (14:09 +0200)
add the arch code for APBH-DMA.

Signed-off-by: Huang Shijie <b32955@freescale.com>
arch/arm/mach-mx6/clock.c
arch/arm/mach-mx6/devices-imx6q.h
arch/arm/plat-mxc/devices/platform-dma.c
arch/arm/plat-mxc/include/mach/dma.h

index 74aa0fb78c1db61465f63dea49355b448c4bab74..1c192b7bee69b713d2ca9272a324ed26145e467f 100644 (file)
@@ -4052,7 +4052,7 @@ static struct clk_lookup lookups[] = {
        _REGISTER_CLOCK(NULL, "hsi_tx", hsi_tx_clk),
        _REGISTER_CLOCK(NULL, "caam_clk", caam_clk[0]),
        _REGISTER_CLOCK(NULL, "asrc_clk", asrc_clk),
-       _REGISTER_CLOCK(NULL, "apbh_dma_clk", apbh_dma_clk),
+       _REGISTER_CLOCK("mxs-dma-apbh", NULL, apbh_dma_clk),
        _REGISTER_CLOCK(NULL, "openvg_axi_clk", openvg_axi_clk),
        _REGISTER_CLOCK(NULL, "gpu3d_clk", gpu3d_core_clk),
        _REGISTER_CLOCK(NULL, "gpu2d_clk", gpu2d_core_clk),
index 94cfd0c7acdb0b990f4af237b060a24cb14faa2e..3f6a3e075b7aa794d1aed55c6e15c84d483a20a9 100644 (file)
@@ -32,6 +32,9 @@ imx6q_anatop_thermal_imx_data __initconst;
 #define imx6q_add_anatop_thermal_imx(id, pdata)        \
        imx_add_anatop_thermal_imx(&imx6q_anatop_thermal_imx_data, pdata)
 
+extern const struct imx_dma_data imx6q_dma_data __initconst;
+#define imx6q_add_dma()        imx_add_dma(&imx6q_dma_data);
+
 #define imx6q_add_gpmi(platform_data)  imx_add_gpmi(platform_data);
 
 extern const struct imx_fec_data imx6q_fec_data __initconst;
index 7a73c230fd44af11af3e6590963e380be4b97f52..b2cba3db6d6d4a98981950f6df1407da03cecfee 100644 (file)
@@ -9,7 +9,7 @@
 #include <linux/err.h>
 #include <linux/init.h>
 
-#include <mach/mx50.h>
+#include <mach/hardware.h>
 #include <mach/devices-common.h>
 
 #ifdef CONFIG_SOC_IMX50
@@ -18,6 +18,12 @@ const struct imx_dma_data imx50_dma_data __initconst = {
 };
 #endif
 
+#ifdef CONFIG_SOC_IMX6Q
+const struct imx_dma_data imx6q_dma_data __initconst = {
+       .iobase = APBH_DMA_ARB_BASE_ADDR,
+};
+#endif
+
 struct platform_device *__init imx_add_dma(
                        const struct imx_dma_data *data)
 {
index ee137b4de1ffcc65d557fb41668f94514c1e928b..04ab43d87d12027d5a5a4790fc3b62fd7d3f1baa 100644 (file)
@@ -77,4 +77,19 @@ static inline int imx_dma_is_general_purpose(struct dma_chan *chan)
                !strcmp(dev_name(chan->device->dev), "imx-dma");
 }
 
+struct mxs_dma_data {
+       int chan_irq;
+};
+
+static inline int mxs_dma_is_apbh(struct dma_chan *chan)
+{
+       return !strcmp(dev_name(chan->device->dev), "mxs-dma-apbh");
+}
+
+static inline int mxs_dma_is_apbx(struct dma_chan *chan)
+{
+       return !strcmp(dev_name(chan->device->dev), "mxs-dma-apbx");
+}
+
+
 #endif