2 * Copyright 2011 Freescale Semiconductor, Inc. All Rights Reserved.
4 * This program is free software; you can redistribute it and/or modify it under
5 * the terms of the GNU General Public License version 2 as published by the
6 * Free Software Foundation.
8 #include <linux/compiler.h>
10 #include <linux/init.h>
12 #include <mach/mx23.h>
13 #include <mach/mx28.h>
14 #include <mach/devices-common.h>
16 static struct platform_device *__init mxs_add_dma(const char *devid,
19 struct resource res[] = {
22 .end = base + SZ_8K - 1,
23 .flags = IORESOURCE_MEM,
27 return mxs_add_platform_device_dmamask(devid, -1,
28 res, ARRAY_SIZE(res), NULL, 0,
32 static int __init mxs_add_mxs_dma(void)
34 char *apbh = "mxs-dma-apbh";
35 char *apbx = "mxs-dma-apbx";
38 mxs_add_dma(apbh, MX23_APBH_DMA_BASE_ADDR);
39 mxs_add_dma(apbx, MX23_APBX_DMA_BASE_ADDR);
43 mxs_add_dma(apbh, MX28_APBH_DMA_BASE_ADDR);
44 mxs_add_dma(apbx, MX28_APBX_DMA_BASE_ADDR);
49 arch_initcall(mxs_add_mxs_dma);