Merge branch 'next' of git://github.com/kernelslacker/cpufreq
[pandora-kernel.git] / arch / arm / mach-omap2 / dma.c
index c9ff0e7..a59a45a 100644 (file)
@@ -87,14 +87,6 @@ static u16 reg_map[] = {
        [CCDN]                  = 0xd8,
 };
 
-static struct omap_device_pm_latency omap2_dma_latency[] = {
-       {
-               .deactivate_func = omap_device_idle_hwmods,
-               .activate_func   = omap_device_enable_hwmods,
-               .flags           = OMAP_DEVICE_LATENCY_AUTO_ADJUST,
-       },
-};
-
 static void __iomem *dma_base;
 static inline void dma_write(u32 val, int reg, int lch)
 {
@@ -228,7 +220,7 @@ static u32 configure_dma_errata(void)
 /* One time initializations */
 static int __init omap2_system_dma_init_dev(struct omap_hwmod *oh, void *unused)
 {
-       struct omap_device                      *od;
+       struct platform_device                  *pdev;
        struct omap_system_dma_plat_info        *p;
        struct resource                         *mem;
        char                                    *name = "omap_dma_system";
@@ -258,23 +250,22 @@ static int __init omap2_system_dma_init_dev(struct omap_hwmod *oh, void *unused)
 
        p->errata               = configure_dma_errata();
 
-       od = omap_device_build(name, 0, oh, p, sizeof(*p),
-                       omap2_dma_latency, ARRAY_SIZE(omap2_dma_latency), 0);
+       pdev = omap_device_build(name, 0, oh, p, sizeof(*p), NULL, 0, 0);
        kfree(p);
-       if (IS_ERR(od)) {
+       if (IS_ERR(pdev)) {
                pr_err("%s: Can't build omap_device for %s:%s.\n",
                        __func__, name, oh->name);
-               return PTR_ERR(od);
+               return PTR_ERR(pdev);
        }
 
-       mem = platform_get_resource(&od->pdev, IORESOURCE_MEM, 0);
+       mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
        if (!mem) {
-               dev_err(&od->pdev.dev, "%s: no mem resource\n", __func__);
+               dev_err(&pdev->dev, "%s: no mem resource\n", __func__);
                return -EINVAL;
        }
        dma_base = ioremap(mem->start, resource_size(mem));
        if (!dma_base) {
-               dev_err(&od->pdev.dev, "%s: ioremap fail\n", __func__);
+               dev_err(&pdev->dev, "%s: ioremap fail\n", __func__);
                return -ENOMEM;
        }
 
@@ -283,7 +274,7 @@ static int __init omap2_system_dma_init_dev(struct omap_hwmod *oh, void *unused)
                                        (d->lch_count), GFP_KERNEL);
 
        if (!d->chan) {
-               dev_err(&od->pdev.dev, "%s: kzalloc fail\n", __func__);
+               dev_err(&pdev->dev, "%s: kzalloc fail\n", __func__);
                return -ENOMEM;
        }
        return 0;